Jump to content

rarebit

Members
  • Posts

    1,002
  • Joined

  • Last visited

Posts posted by rarebit

  1. I've recently changed the theme of my new site and i'm a bit unsure. It was orange and the font was 'lighter', so i've made it somewhat bolder, using blue and red. Not that I dislike it, but I don't prefer it. However at least the forum isn't orange now (a bit off putting me thought):

     

    http://www.lovemap.co.uk

     

    If you need to subscribe this code 'FREE_FREAK_6' will give you 6 months for free (also without inputting ant cc details).

     

    Many Thanks!

  2. p.s. using ie6 the anims seem a bit jittery and have an issue which reloads the images (not that i've gone to extent of preloading, even though the ones it loads are definitely already loaded). Also when you solve the puzzle it flashes everything, very strange. This are all ie6 issues.

     

    Yes - it starts and resets to a simple solution, so it's quick to test, proper is commented out.

    Yes - The brown square zindex has some issues at times, to be looked into.

    Yes - Theres a few more issues, but when I spend time on it i'll sort them...

  3. I don't think you comprehend what I was doing, basically because you removed the function entirely, even though the post title inferred the use of a function. Once again this was just a test example and in the real thing it doesn't use 'document.write', but could you explain why it's bad to use it?

  4. What country postcode are you working on? If it's UK, then it might be third character (can't rem if theres possibility of 4). Any which way though...

    if, if, if
    document.write(pc.substring(0, 3) + " " + pc.substring(4, pc.length));
    

    this might need a slight tweet since it's not tested...

  5. I think you missed the point of a function returning numerous variables, yes I was using the modern interpretation, like many modern languages allow (e.g. FF, Opera). The example was just that, a simple example, so getting rid of the function was inappropriate, too obvious to be true, but I 'pose I did give the bone...

  6. hmm, found the problem...

    obj.attachEvent('onclick', function(evt) { sg_click(obj, id); });
    obj.attachEvent('mouseover', function(evt) { sg_over(obj, id); });
    obj.attachEvent('mouseout', function(evt) { sg_out(obj, id); });
    

    now changed to...

    obj.attachEvent('onclick', function(evt) { sg_click(obj, id); });
    obj.attachEvent('onmouseover', function(evt) { sg_over(obj, id); });
    obj.attachEvent('onmouseout', function(evt) { sg_out(obj, id); });
    

     

    My question is, why didn't IE tell me it had a problem with this?

    What is best way to check scripts for IE compatibility?

  7. Hi,

     

    I've been trying to get a page working in IE (it's fine in FF2 + Opera). I've not used windows or IE for quite a while, so it's somewhat alien to me. I seem to have got rid of all errors and the page initialises, however you can't play the game. Can anyone point me in the right direction please?

     

    I've hosted a demo on dev site temporally here: http://retro.monkies.co.uk/

     

     

     

    p.s. the way it's set you can complete in either 3 or 9 moves easily!

  8. No you won't, it's know as a GET statement (from a form is a POST). Basically anything after the ? is passed a a key value pair to the php interpreter, you can have multiple sets by delimiting with &. You can call the variables whatever you want, id is just easily descriptive (honestly). So:

     

    <a href="login.php?name=me&pass=password">login</a>
    

     

    not the best example but it illustrates the point. Next you need to get the variable, it's held in an array called $_GET (see reserved variables).

     

    if(isset($_GET['name']))
    {
    echo "name: ".$_GET['name']."<br>";
    }
    
    if(isset($_GET['pass']))
    {
    $pass = $_GET['pass'];
    echo "pass: ".$pass."<br>";
    }
    

  9. Thats how I learnt, and I also think it's the best way...

    But if you just want the easy answer, then:

    <?php
    $WStart = "xxx";
    $WStop = "yyy";
    $SStart = "zzz";
    $SStop = "aaa";
    $GStart = "bbb";
    $GStop = "ccc";
    
    $s = "<?=\$WStart?>Urban%20Renewal<?=\$WStop .\$SStart?>Urban%20Renewal<?=\$SStop .\$GStart?>Urban%20Renewal<?=\$GStop?>";
    
    ob_start();
    $x = eval("?>".$s);
    $l = ob_get_contents();
    ob_end_clean();
    
    print $l."<br>";
    ?>
    

     

    I've added escaping slashes to the original string otherwise in this situation the variables would replace them. If reading a file or something, this wouldn't be a problem.

     

    After you've called 'ob_start()' nothing will be outputted to stdout until you call some form of 'ob_end'...

     

    Not that i've recently read the manual, but i'd say $x holds the result, e.g. if it executed ok...

  10. are you wanting to do this or someone else to do it for you?

     

    The new part will be client specific and therefore nothing to with php. A file upload feature is half client / half server, but thats easy and another question.

     

    Back to the original question:

     

    Once file is uploaded, you could use some form of the 'exec' command to run a system ocr program and then read its output. Once again what program you use depends upon what os your server runs and if or what is installed (e.g. if your host will install, if not your own server or a slice)

  11. function test()
    {
    var x = 3;
    var y = 7;
    return [x, y];
    }
    
    var a;
    a = test();
    document.write('a: ' + a[0] + ', b: ' + a[1] + '<br>');
    

    This is what I tried this morning and it gave no errors but the explorer version still isn't working. So i've finally installed comodo and will get my windows online and find something to help debug it.

     

    No this example doesn't really do anything, it was just a testbed for the question. There's another variation to use 'pointers' but i've not looked into it with js (just saw a comment and thought i'd give it a quick try).

     

    I'll add your part and see if ie bails out.

     

    Cheers

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.