Help with first pages

8 posts by 3 authors in: Forums > CMS Builder
Last Post: February 16, 2009   (RSS)

Re: [tonycook] Help with first pages

I deleted a couple of my own replies to this thread, as I worked away at developing two initial pages for newsList and newsDetail (they remain different in design - ignore that, as I am concentrating on simply getting 'List" to display 'Detail', which it doesn't.) These earlier replies are now redundant.

Can anyone tell me why the links on newsList do not open the corresponding pages in newsDetail? Is this a db problem.
Tony Cook
Searoom Communications, Toronto, Canada
www.searoom.com
www.boatsell.com
www.boatsell.ca

Re: [tonycook] Help with first pages

By ross - February 16, 2009

Hi Tony

Thanks for posting!

When you go to a detail page you need to tell it what record number you want it to display. Otherwise, it will just display the first one in its list.

So, if you just go to:

http://www.searoom.com/testbed/news/newsDetail.php

you are always going to see the first record. If you wanted to get to the second record, you would use a URL like this:

http://www.searoom.com/testbed/news/newsDetail.php?2

That "2" at the end will change depending on the record number.

Now, the thing here is that the link to your detail page should actually automatically fill in if you are using the code from the code generator on your list page so I am not quite sure how you have that all setup.

Does the part about that number in the URL help? Let me know if we can go over this in more detail together.

Thanks!
-----------------------------------------------------------
Cheers,
Ross Fairbairn - Consulting
consulting@interactivetools.com

Hire me! Save time by getting our experts to help with your project.
Template changes, advanced features, full integration, whatever you
need. Whether you need one hour or fifty, get it done fast with
Priority Consulting: http://www.interactivetools.com/consulting/

Re: [ross] Help with first pages

By tonycook - February 16, 2009 - edited: February 16, 2009

Thanks Ross:
Attached is newslist.txt containing all of the code from my current newsList.php file

I cannot see how to insert the record numbers.
Tony Cook
Searoom Communications, Toronto, Canada
www.searoom.com
www.boatsell.com
www.boatsell.ca
Attachments:

newslist.txt 4K

Re: [tonycook] Help with first pages

I forgot to include newsdetail.txt
Tony Cook
Searoom Communications, Toronto, Canada
www.searoom.com
www.boatsell.com
www.boatsell.ca
Attachments:

newsdetail.txt 6K

Re: [tonycook] Help with first pages

Ross wrote:
So, if you just go to:

http://www.searoom.com/testbed/news/newsDetail.php

you are always going to see the first record.


The point is, the browser does not find the detail page.
Tony Cook
Searoom Communications, Toronto, Canada
www.searoom.com
www.boatsell.com
www.boatsell.ca

Re: [tonycook] Help with first pages

By Dave - February 16, 2009

Hi Tony,

When I go to the list page here: http://www.searoom.com/testbed/news/newsList.php and click a link I get this: http://www.searoom.com/testbed/news/newsDetail.php%20?Canadian-Boat-Licence-1

Which doesn't work. But if I remove the %20 it does. It looks like an extra space is getting added in the url.

In the CMS go to: Admin > Section Editors > News > Viewer Urls (tab) > Detail Page Url

and remove the trailing space off the end of the url in the "Detail Page Url" field. Then click "Save" and try the links from the list page again and let me know if they work.

Hope that helps!
Dave Edis - Senior Developer
interactivetools.com

Re: [Dave] Help with first pages

Dave:

That fixed the problem - many thanks!
Tony Cook
Searoom Communications, Toronto, Canada
www.searoom.com
www.boatsell.com
www.boatsell.ca