www.webdeveloper.com

Search:

Type: Posts; User: HaganeNoKokoro

Page 1 of 20 1 2 3 4

Search: Search took 0.03 seconds.

  1. Replies
    5
    Views
    4,135

    I'd put all that functionality in a function,...

    I'd put all that functionality in a function, just to keep the code cleaner. I'd go with something like this (the red is stuff I added or changed):
    <script type="text/javascript">
    /*
    * a function...
  2. The way you're doing it now $query = "DELETE...

    The way you're doing it now
    $query = "DELETE FROM calendar_events WHERE day < ".$_GET['day']." AND month < ".$_GET['month']." AND year < ".$_GET['year']."";no events from the current year will be...
  3. Replies
    4
    Views
    1,396

    If you move the menu-files directory (with the...

    If you move the menu-files directory (with the menu_scr.js file in it) to the root of your site, then you should be able to include it in pages like this:
    <script type="text/javascript"...
  4. Replies
    4
    Views
    1,396

    What they're saying is, instead of including the...

    What they're saying is, instead of including the file with a script tag that says
    <script language="JavaScript" type="text/javascript" src="menu-files/menu_scr.js">
    </script>Use a script tag like...
  5. Replies
    8
    Views
    1,063

    For this, I think you have to use the meta...

    For this, I think you have to use the meta refresh tag in the <head> section of your page:
    <meta http-equiv="Refresh" content="2; url=news.html">
  6. Replies
    5
    Views
    1,053

    to prompt the user for text input, use the prompt...

    to prompt the user for text input, use the prompt method:
    <script type="text/javascript">
    function getLinkInfo() {
    var theURL=prompt("Please Enter a URL", window.location);
    if(theURL==null)...
  7. Replies
    8
    Views
    1,249

    You shouldn't need javascript for this. If it's...

    You shouldn't need javascript for this. If it's only going to be the one set of 15 thumbnails, you won't even need a server-side language.

    No javascript, no server-side approach:

    Basically,...
  8. Replies
    1
    Views
    5,157

    Scary Javascript Date/Time Bug

    I've come across a really bizarre bug in the JScript and Javascript Date object. I have a calendar script that uses something like this to determine the first day of the month:
    var firstDate=new...
  9. Another thought: Are you setting the expiry...

    Another thought:

    Are you setting the expiry for the cookie? The default is for the cookie to expire th the end of browser session (when the browser closes).
  10. And you're sure firefox has the cookie (checked...

    And you're sure firefox has the cookie (checked the cookie manager)? Also, go to about:config in firefox and filter for "redirect" to see if it's set to not follow redirects for some reason.
  11. Is it possible IE was blocking the cookie? Does...

    Is it possible IE was blocking the cookie? Does IE give any sort of error message, or does it just sit there?
  12. If their IE is blocking javascript, there's...

    If their IE is blocking javascript, there's nothing more you can do with that approach.

    Since you have php, it would be better to do this on the server-side. I believe there's a $_COOKIE...
  13. Replies
    3
    Views
    1,661

    Try using an editor that doesn't know or care...

    Try using an editor that doesn't know or care what any of the non-editable / template stuff means, like notepad.
  14. Replies
    2
    Views
    1,195

    You could probably use the javascript onunload...

    You could probably use the javascript onunload event. That fires when the browser leaves your page (either closing or going to another page).
  15. Replies
    2
    Views
    1,083

    You can't just treat the ids as javascript...

    You can't just treat the ids as javascript variables pointing to HTML elements (lager1, lager2). You have to use document.getElementById to get references to the elements. You can do this every time...
  16. That wouldn't be as good, for example, then you...

    That wouldn't be as good, for example, then you could put

    dgdsag dasgsadg dasgdsagdsa gsdag dasgs@example.comhtdfujrtuj rtdjdrd fgjf

    and it would still match.
  17. Another way to do it would be to change your...

    Another way to do it would be to change your regexp to allow leading and trailing whitespace:
    Replace your regexpwith this one
    /^[\s]*\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,3})+[\s]*$/The blue...
  18. Replies
    13
    Views
    2,896

    You can't do it with php. There might be some...

    You can't do it with php. There might be some sort of trick to prevent the page from being accessed directly (though nothing I can think of), and all the frames and no-right-click scripts in the...
  19. Replies
    0
    Views
    868

    Good, it didn't work

    nevermind
  20. Replies
    2
    Views
    1,098

    Try the tabindex property:...

    Try the tabindex property: http://www.w3.org/TR/REC-html40/interact/forms.html#h-17.4
  21. Here's a regex I've been playing with:

    Here's a regex I've been playing with:
    <?php
    $regex="/<a(?:.*?)href[\\s]*\\=[\\s]*([\\\"'])(.*?)\\1(?:.*?)>(.*?)<\\/a>/";
    $mats=array();
    preg_match_all($regex, "<a class=\"test\"...
  22. Replies
    3
    Views
    1,010

    What error are you getting? ...

    What error are you getting?

    document.getElementById(field) has no properties
    or
    object does not support this property or method
    or
    <something else>
    ?

    It might help to see the full source...
  23. Replies
    5
    Views
    1,451

    Here are some pre-packed cookie handling...

    Here are some pre-packed cookie handling functions you may find useful: http://www.webreference.com/js/column8/functions.html
  24. Replies
    5
    Views
    1,451

    Not at all. You could use document.createElement...

    Not at all. You could use document.createElement to create the links and append them as children to an element in the document. I'd put a <DIV> on my page where I want the links to be written
    <div...
  25. Replies
    5
    Views
    1,451

    You can't submit a form to a javascript like...

    You can't submit a form to a javascript like that. You also can't just pass the names of form inputs and expect it to figure out you want it to find the values (it'll think you're trying to refer to...
Results 1 to 25 of 500
Page 1 of 20 1 2 3 4
HTML5 Development Center



Recent Articles