Skip to content
View in the app

A better way to browse. Learn more.

Web Designer Forum

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

how do i limit my search result to be echod

Featured Replies

Hello Friends,

 

I am developing a website where vacancies can be posted. Enployers will have to fill a form which include number of I weeks the vacancies would be available. I have a table in my database where the entries will be kept. I have converted the number of weeks the vacancies will be available to days and have added it to the date which the vacancy is posted to get the date the vacancy will expire. On my home page where the visitors can view the avalable vacancies, I tried subtract today's (everyday) date from the expiry date and echo the result of vacancies which are still available. i used the code below but it didn't work

<?
$table_name=vacancies;
$column_name=end_date;
$date=date("d M y", time());
$getvac=mysql_query("SELECT * FROM $table_name WHERE $column_name - $date > 0 ORDER BY id DESC");
if(mysql_num_row($getvac)==0)
echo "NO VACANCY IS AVAILABLE.";
else
{$result=mysql_fetch_array($getvac);
...}
?>

 

The end date is also in this format date("d M y"). But am receiving this error

Warning: mysql_num_rows(): supplied argument is not a valid Mysql result resource

Pls what can i do or what are the other ways out because i want to echo only those vacancies whose end_date is greater than zero.

 

regards

adsegzy

Create an account or sign in to comment

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.