Solarpitch Posted February 26, 2008 Share Posted February 26, 2008 Hey, I am just looking to embed the mouseover command into this link. Can someone just take a look and see if its embedded correctly. I am not sure if it is. I think its a problem with the string inside the ddrivrtip function. Cheers <?php echo "<a href='sign_out.php?logout=1' onMouseover='ddrivetip('Where do ya think your going?','yellow', 300)'; ONMOUSEOUT='hideddrivetip()';>Logout</a>"; ?> Link to comment https://forums.phpfreaks.com/topic/93181-quick-syntax-question/ Share on other sites More sharing options...
aebstract Posted February 26, 2008 Share Posted February 26, 2008 The php is fine.. the rest is javascript. Link to comment https://forums.phpfreaks.com/topic/93181-quick-syntax-question/#findComment-477374 Share on other sites More sharing options...
Solarpitch Posted February 26, 2008 Author Share Posted February 26, 2008 Yeah but I am embedding into a php statement. I know the php is fine, thats tested and working ok... I am just asking if some can check the syntax of the JS embedded into the echo statement Link to comment https://forums.phpfreaks.com/topic/93181-quick-syntax-question/#findComment-477382 Share on other sites More sharing options...
php_dave Posted February 26, 2008 Share Posted February 26, 2008 If i remember from the last time i did this you will have to replace the ' for " and escape them /" inside the java function brackets - sorry has been a while.. Im sure someone will know. I have some code at work that does this - I will post it tomorrow if no one comes up trumps for you! Dave Link to comment https://forums.phpfreaks.com/topic/93181-quick-syntax-question/#findComment-477387 Share on other sites More sharing options...
Solarpitch Posted February 26, 2008 Author Share Posted February 26, 2008 Cheers Dave, Its awhile since I done that mysefl but I think your right! I am not sure of the way to use the escape... if anyone can show that would be great! Link to comment https://forums.phpfreaks.com/topic/93181-quick-syntax-question/#findComment-477392 Share on other sites More sharing options...
aebstract Posted February 26, 2008 Share Posted February 26, 2008 I am just asking if some can check the syntax of the JS embedded into the echo statement That belongs in a php help forum? Link to comment https://forums.phpfreaks.com/topic/93181-quick-syntax-question/#findComment-477394 Share on other sites More sharing options...
Solarpitch Posted February 26, 2008 Author Share Posted February 26, 2008 Look aebstract ... if you dont want to help, forget about it mate! Link to comment https://forums.phpfreaks.com/topic/93181-quick-syntax-question/#findComment-477395 Share on other sites More sharing options...
aebstract Posted February 26, 2008 Share Posted February 26, 2008 ...Probably get a more useful answer in a Javascript help section. Not that I don't want to help (I don't know javascript for beans) which is why I'm in the php area and not the javascript Link to comment https://forums.phpfreaks.com/topic/93181-quick-syntax-question/#findComment-477399 Share on other sites More sharing options...
revraz Posted February 26, 2008 Share Posted February 26, 2008 It's a valid point, if you want JS help, then ask in the JS forums. Link to comment https://forums.phpfreaks.com/topic/93181-quick-syntax-question/#findComment-477400 Share on other sites More sharing options...
Solarpitch Posted February 26, 2008 Author Share Posted February 26, 2008 I am not getting into an argument... just dont have the time! But I would have thought a php syntax question would have been the PHP forum? Forget the javascript... the problem is with the string... if I replace the javascript with a string saying something esle.. would it then be valid for the php help forum Link to comment https://forums.phpfreaks.com/topic/93181-quick-syntax-question/#findComment-477402 Share on other sites More sharing options...
php_dave Posted February 26, 2008 Share Posted February 26, 2008 I think this is it mate, <?php echo "<a href='sign_out.php?logout=1' onMouseover=\"ddrivetip('Where do ya think your going?','yellow', 300)\"; ONMOUSEOUT=\"hideddrivetip()\";>Logout</a>"; ?> Link to comment https://forums.phpfreaks.com/topic/93181-quick-syntax-question/#findComment-477408 Share on other sites More sharing options...
revraz Posted February 26, 2008 Share Posted February 26, 2008 This would be valid, yes. <?php echo "<a href='sign_out.php?logout=1'>Logout</a>"; ?> Link to comment https://forums.phpfreaks.com/topic/93181-quick-syntax-question/#findComment-477410 Share on other sites More sharing options...
Solarpitch Posted February 26, 2008 Author Share Posted February 26, 2008 Cheers for that Dave! All sorted! sound man Link to comment https://forums.phpfreaks.com/topic/93181-quick-syntax-question/#findComment-477413 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.