close ad
Databridge V2 with MySQLi support IS Now Available!
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

news page content not displaying

Thread began 1/22/2013 7:07 am by JamieEff | Last modified 1/23/2013 1:27 pm by Jason Byrnes | 837 views | 10 replies |

JamieEff

news page content not displaying

Hey Jason

Have created a news section using databridge

I am trying to get it to display the news item here:

news2.php

By default, when you navigate to the page it should be the most recent article.

As you can see, the news navigation is displaying fine (and when clicked should open in the same page)

Thanks

Jamie

Sign in to reply to this post

Jason ByrnesWebAssist

i'll need a copy of the page so i can see the code.

Sign in to reply to this post

JamieEff

here you go Jason and thanks

also, on the same site... am using a show region for the click hereon this page councillors.php but it isnt working as click here shows regardless...

php:
<?php if ($totalRows_Councillors 0) { // Show if recordset not empty ?>
  <a href="mailto:<?php echo $row_Councillors['CouncillorsEmail']; ?>">click here</a>
  <?php // Show if recordset not empty ?>
Attached Files
news2.zip
Sign in to reply to this post

Jason ByrnesWebAssist

you are using the same recordset for showing the news items and for showing the links.


you need to use one recordset for showing the links.

and a second recordset for showing the news items.

in the second recordset, se it to filter the ID column on the ID URL Variable.

to show a default news item, go to advanced view for the recordset, and set the default value for the URL parameter to the ID of the news item that should be the default.



for the issue with the email link, the if statement is just checking that the recordset is not empty, since the recordset is what is used to populate the list, it is not empty (otherwise the list would be empty to, no?)


I believe you want to be checking if the email column is empty?
<?php if ($row_Councillors['CouncillorsEmail'] != "") { ?>

Sign in to reply to this post

JamieEff

Thanks JAson

Re:

  to show a default news item, go to advanced view for the recordset, and set the default value for the URL parameter to the ID of the news item that should be the default.  


Not sure what I need to put here... and the default would be the most recent article...

Re the show if issue, the recordset is empty (there is nothing in the column in the database).

Sign in to reply to this post

Jason ByrnesWebAssist

the i guess you would need a third recordset to lookup the most recent article, and use that one if there are no records in the other recordset.


  Re the show if issue, the recordset is empty (there is nothing in the column in the database).  



those aren't the same thing. an empty column in the database does not mean that the recordset is empty.

the recordset is clearly not empty, otherwise, you would not be showing the names in the list.

Sign in to reply to this post

JamieEff

ahhh sorry, wasnt making the distinction re the show if - have now done so! workign a dream :D

Sign in to reply to this post

JamieEff

Hey Jason

Am struggling with the news thing still.

Have tried doing it on another site with its blog. blog.php

I have got the blog navigation working fine... and when yuou click on a certain blog title it opens the relevant article on the left hand sdie

However, I cannot figure out how to get it so that when you click on the main 'blog' link in the top navigation the most recent article is displayed with the navigation down the right and then any subsequent blog navigation selections opens in the same page....

Many thanks in advance

Jamie

Sign in to reply to this post

Jason ByrnesWebAssist

if you order the recordset by the ID column in ascending order, the most recent blog will be the first record in the recordset.

Sign in to reply to this post

JamieEff

I just cant get it to work.. have tried playing around with a variety of different orders. At the moment I have it set upa attached images) of both recordsets and the table itself

Basically as its set up at the moment the most recent article is visible in the left hand column, but none of the links work to navigate the other blog titles....

Attached Files
table.zip
Sign in to reply to this post
loading

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...