Jump to content

mccrum

New Members
  • Posts

    5
  • Joined

  • Last visited

    Never

Everything posted by mccrum

  1. Hi, im looking to pull 3 posts from a specific Wordpress Category. At the minute I can pull 3 latest posts and display them in a flash banner using the code below. SELECT yah_posts.*, yah_postmeta.* FROM yah_posts LEFT JOIN yah_postmeta ON yah_posts.ID = yah_postmeta.post_id WHERE yah_postmeta.meta_key = 'largeimage' && yah_posts.post_status = 'publish' ORDER BY post_date DESC LIMIT 3 I want to be able to pull 3 latest posts from a specific category instead of just 3 latest posts from every category. I have put together this code below, but it doesn't seem to be working $query = "SELECT yah_posts.*, yah_postmeta.* FROM yah_posts LEFT JOIN yah_postmeta ON yah_posts.ID = yah_postmeta.post_id AND LEFT JOIN $yah_term_taxonomy ON($yah_term_relationships.term_taxonomy_id = $yah_term_taxonomy.term_taxonomy_id) WHERE yah_postmeta.meta_key = 'largeimage' && yah_posts.post_status = 'publish' AND $yah_term_taxonomy.term_id = '1' AND $yah_term_taxonomy.taxonomy = 'category' ORDER BY post_date DESC LIMIT 3";
  2. I have put together a 5 star rating system using PHP and Ajax which will write the rating into a database. http://andrewmccrum.com/maps/rate/5star.php I want this rating system to work within a Google Maps InfoWindow but at the minute I can only get the InfoWindow to read and display the rating. It will not let the user vote like the top link. And I have no idea why http://andrewmccrum.com/maps/database/index.php
  3. Ok I think I have it working now, the only problem is I can not get the error to show up if you enter the wrong username or password. I would like the same error box to show up as I had in the first set of code I posted, here is my new code without the error, currently it just reloads the login form if you enter a wrong username/password:
  4. I made a simple PHP login form that uses only 1 username and password to login. If I currently type in the correct username and password it displays "LOGIN SUCCESSFUL" and shows a link to the admin page but I would like to include the admin page within the php file. Below is the code I have used, hope you can help.
  5. I made a simple PHP login form that uses only 1 username and password to login. If I currently type in the correct username and password it displays "LOGIN SUCCESSFUL" and shows a link to the admin page but I would like to include the admin page within the php file. Below is the code I have used, hope you can help.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.