Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much
 
PerlMonks  

comment on

( [id://3333]=superdoc: print w/replies, xml ) Need Help??

You have this:

<!-- Next Photo Button Form --> "<button onclick="window.navigate'"; "http://www.timmillerphotography.com/cgi-bin/wedding_view_photo.pl?id= +20122&more=Becky_and_Jason&name=Before_the_Ceremony&value="; ["+1"]; "&goback=&select='; "">Next</button> <!-- Next Photo Button Form --> + <!-- Back Button Form --> <form action="http://www.timmillerphotography.com/cgi-bin/wedding_view +.pl" method="POST"> <input type="hidden" name="class" value=Before_the_Ceremony> <input type="hidden" name="value" value=Before_the_Ceremony> <input type="hidden" name="place" value=1> <input type="hidden" name="student" value=C173B200.jpg> <input type="hidden" name="select" value=> <input type="hidden" name="id" value=20122> <input type="hidden" name="more" value=Becky_and_Jason> <input type="hidden" name="recipientnum" value="+1"> <input type="submit" value="BACK" name="back"> </form> <!-- Back Button Form -->

The top section is gibberish. You are trying to use javascript to call a Perl CGI but don't seem to have much of a clue about what is and is not valid HTML/javascript syntax.

The OUTPUT that is generated by the Perl CGI needs to change to be:

<button onclick="window.navigate('http://www.timmillerphotography.com/ +cgi-bin/wedding_view_photo.pl?id=20122&more=Becky_and_Jason&name=Befo +re_the_Ceremony&goback=&select=&value=+1')">Next</button>

This needs to be generated in your Perl code. BUT it does not work as is because the CGI does not understand the concept of a value +1. It wants something C173B202.jpg as a value where this value is the name of the next picture to display.

You need to post some of the Perl code if you want more useful help. When your code displays an image it needs to get the name of the next image. This will be at index +1 if the names are in an array which is probably what your +1 represents. You then need to output HTML that looks like the example above with the +1 fixed.

cheers

tachyon


In reply to Re: next and previous buttons by tachyon
in thread next and previous buttons by waggz

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":



  • Are you posting in the right place? Check out Where do I post X? to know for sure.
  • Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
    <code> <a> <b> <big> <blockquote> <br /> <dd> <dl> <dt> <em> <font> <h1> <h2> <h3> <h4> <h5> <h6> <hr /> <i> <li> <nbsp> <ol> <p> <small> <strike> <strong> <sub> <sup> <table> <td> <th> <tr> <tt> <u> <ul>
  • Snippets of code should be wrapped in <code> tags not <pre> tags. In fact, <pre> tags should generally be avoided. If they must be used, extreme care should be taken to ensure that their contents do not have long lines (<70 chars), in order to prevent horizontal scrolling (and possible janitor intervention).
  • Want more info? How to link or How to display code and escape characters are good places to start.
Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others romping around the Monastery: (3)
As of 2024-04-25 23:50 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found