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.

Help with an idea

Featured Replies

Yea... soo.. basically i need help with putting together a search on the front a website im designing to display pics of the date they search.

 

i have a form on the front page, they select the day, the month and year....

 

when they click submit im looking to display all pics taken on that date. or even just display the archives taken on that date, so they can look into each archive.

 

im thinking im going to have to submit each picture into my mysql database with that date on it?

 

Or create a .php file with that date (e.g 12022009.php) then that page will have the pictures on, so that when they search the date, it changes the URL to http://www.site.com/12022009.php, or http://www.site.com/archive.php?date=12022009

 

i hope ive explained this well enough - any help on how i do this would be appretiated

Yea... soo.. basically i need help with putting together a search on the front a website im designing to display pics of the date they search.

 

i have a form on the front page, they select the day, the month and year....

 

when they click submit im looking to display all pics taken on that date. or even just display the archives taken on that date, so they can look into each archive.

 

im thinking im going to have to submit each picture into my mysql database with that date on it?

 

Or create a .php file with that date (e.g 12022009.php) then that page will have the pictures on, so that when they search the date, it changes the URL to http://www.site.com/12022009.php, or http://www.site.com/archive.php?date=12022009

 

i hope ive explained this well enough - any help on how i do this would be appretiated

 

Add each image to the database with the date in unix time format...

 

Then do something like below:

 

//users search

$date=$_GET['date'];

$date_day = date('d', $date); // Seperate the day into a variable 
$date_month = date('m', $date); // Seperate the month into a variable 
$date_year = date('Y', $date); // Seperate the year into a variable 

$query="SELECT date, filename FROM images ".
		"ORDER BY date ASC";

$result=mysql_query($query); $num=mysql_num_rows($result);

if ($num != '0') {

while ($row = mysql_fetch_assoc($result)) {

	$image_date_day = date('d', $row['date']); // Seperate the day into a variable 
	$image_date_month = date('m', $row['date']); // Seperate the month into a variable 
	$image_date_year = date('Y', $row['date']); // Seperate the year into a variable

	if ($date_year == $image_date_year) {
				if ($date_month == $image_date_month) {
						if ($date_day == $image_date_day) {
								  //OUTPUT IMAGE HERE
								  //OR
								  //PUT IMAGE INTO AN ARRAY AND OUTPUT TOGETHER LATER
					}
				}
			}
}

}

 

I hope that helps....

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.