Advertisement
Help Keep Boards Alive. Support us by going ad free today. See here: https://subscriptions.boards.ie/.
If we do not hit our goal we will be forced to close the site.

Current status: https://keepboardsalive.com/

Annual subs are best for most impact. If you are still undecided on going Ad Free - you can also donate using the Paypal Donate option. All contribution helps. Thank you.
https://www.boards.ie/group/1878-subscribers-forum

Private Group for paid up members of Boards.ie. Join the club.

need a quick bit of help here

  • 06-12-2005 07:41PM
    #1
    Banned (with Prison Access) Posts: 8,483 ✭✭✭


    figured this would be better here than in webmaster forum, the following line of code is throwing up a syntax error on me
    <a href="#" OnClick="window.open('1.html','my_window','width=620, height=435'); onMouseOut="MM_swapImgRestore();"  onMouseOver="MM_swapImage('xx_r9_c16','','images/messages_on.jpg',1);"><img name="xx_r9_c16" src="images/xx_r9_c16.jpg" width="100" height="27" border="0" alt=""></a>
    

    anyone any idea what im missing here?


Comments

  • Closed Accounts Posts: 17,208 ✭✭✭✭aidan_walsh


    No closing " after onClick.


  • Banned (with Prison Access) Posts: 8,483 ✭✭✭miju


    ah sweet, i really hate debugging :-(

    nice one man, mucho appreciated


  • Registered Users, Registered Users 2 Posts: 19,396 ✭✭✭✭Karoma


    OnClick="window.open('1.html','my_window','width=620, height=435');"
    too slow:)


  • Registered Users, Registered Users 2 Posts: 6,342 ✭✭✭OfflerCrocGod


    Use firefox it can catch these errors. Tools -> Javascript Console and then load up your webpage any errors come up in the console and it's easy to fix :)
    Error: unterminated string literal
    Source File: javascript: OnClick="window.open('1.html','my_window','width=620, height=435');
    Line: 1, Column: 9
    Source Code:
    OnClick="window.open('1.html','my_window','width=620, height=435');
    It's a great help.


  • Registered Users, Registered Users 2 Posts: 68,173 ✭✭✭✭seamus


    For better compatibility, I recommend you use:

    [html]<a href="1.html" target="_blank" OnClick="window.open('1.html','my_window','width=620, height=435');return false;">[/html]
    If the client has Javascript enabled, the "return false" stops the window from being opened twice. If the client has Javascript disabled, the window will still open.


  • Advertisement
  • Moderators, Politics Moderators, Paid Member Posts: 44,042 Mod ✭✭✭✭Seth Brundle


    A decent [text] editor should colour code these also!


  • Registered Users, Registered Users 2 Posts: 8,575 ✭✭✭Trampas


    editplus is a free text editor


  • Moderators, Politics Moderators, Paid Member Posts: 44,042 Mod ✭✭✭✭Seth Brundle


    There was a thread here recently on good free text editors and loads were listed.
    Any good editor will have syntax highlighting and should quickly allow the user to spot unterminated strings.


  • Banned (with Prison Access) Posts: 8,483 ✭✭✭miju


    thanks for the help guys, yiz are all legends so yiz are:D


Advertisement