Wrox Programmer Forums
|
BOOK: Beginning PHP4/PHP 5 ISBN: 978-0-7645-4364-7; v5 ISBN: 978-0-7645-5783-5
This is the forum to discuss the Wrox book Beginning PHP4 by Wankyu Choi, Allan Kent, Chris Lea, Ganesh Prasad, Chris Ullman; ISBN: 9780764543647
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Beginning PHP4/PHP 5 ISBN: 978-0-7645-4364-7; v5 ISBN: 978-0-7645-5783-5 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old July 5th, 2003, 09:20 AM
Registered User
 
Join Date: Jul 2003
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default Chp 12 - userviewer.php problems w/ hyperlinks

Hello,
The hyperlinks in the html output from userviewer.php are non-functional and I can't figure out
why? i.e "Next; Bottom; View Record;" and those in the Table header "User Number; User
Name; & User ID;" All with the exception of "View Record" return the following error message
below, "View Record" does nothing.

Any suggestions appreciated - Thanks
-- Joe --

    Bad Request

    Your browser sent a request that this server could not understand.

    The request line contained invalid characters following the protocol string.


From apache error log file:
    request failed: erroneous characters after protocol string: GET /php/?action=list_records& sort_order=ASC& order_by=usernumber& cur_page=1 HTTP/1.0

Link rewritten and placed on one single line ==>

Index of /php
i'e. the directory tree where the files are located, again "View Record" does nothing

Thanks
-Joe-

 
Old July 7th, 2003, 04:05 AM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 256
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Looks like you are including tabs or spaces in your code which are getting included into your hrefs. Let me guess, does the href go onto multiple lines, thus?

                 <a href="/php/?action=list_records&
                                sort_order=ASC&
                                order_by=usernumber&
                                cur_page=1">et cetera...

If, so, put it all on one line and remove all that white space. I'll bet the href attribute didn't originally have double quotes around it, when it was originally written, and worked in Explorer simply because the browser curtained all that white space into single %20s. Generally, HTML doesn't care about white space, but if you enclose your attributes in quotes (as you certainly should) any white space will be included into the attribute.

If you let us have a quick look at the code that's generating the problem, we'll probably be able to confirm this.

Dan

Sales brochure for MS Office that just came through my door:
"Not just an upgrade. A whole new revenue opportunity."
Ha ha ha!

"Assume the position: it's time to realy start generating some revenue!"
 
Old July 10th, 2003, 04:54 PM
Registered User
 
Join Date: Jul 2003
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default

The broken lines were removed, but then the error was of a page not found type, displaying the directory tree.

If someone has a working copy of a common_db.inc and the userviewer.php files set up for use with 'register_global' = Off, and would like to share it with myself or the community, the gesture would be greatly appreciated. The use of $_GET['variable'] or $_POST['variable'] would be irrelevant as it desired only for use as a template illustrating the correct syntactic and positional use in the files.

Thanks






Similar Threads
Thread Thread Starter Forum Replies Last Post
Chp.12 'custom' SqlDataSource and paging studen77 BOOK: Professional ASP.NET 2.0 Server Control and Component Development ISBN: 978-0-471-79350-2 8 April 4th, 2007 05:49 PM
Chp.12 SqlDataSource.SelectCountCommand ??? studen77 BOOK: Professional ASP.NET 2.0 Server Control and Component Development ISBN: 978-0-471-79350-2 4 March 7th, 2007 02:50 PM
Chp 12, common_db.inc & userviewer.php reques jaymax BOOK: Beginning PHP4/PHP 5 ISBN: 978-0-7645-4364-7; v5 ISBN: 978-0-7645-5783-5 1 February 1st, 2006 05:18 PM
Problems width userviewer ch.12 compac BOOK: Beginning PHP4/PHP 5 ISBN: 978-0-7645-4364-7; v5 ISBN: 978-0-7645-5783-5 2 March 28th, 2005 10:07 AM
Ch. 12 userviewer.php -> modify Tachyon BOOK: Beginning PHP4/PHP 5 ISBN: 978-0-7645-4364-7; v5 ISBN: 978-0-7645-5783-5 1 May 18th, 2004 12:38 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.