Color Inspiration: Awesome Red Websites

Color Inspiration: Awesome Red Websites

Red is a very powerful and strong color. It’s associated with a variety of things, from courage and bravery to warnings and danger. It’s also, of course, strongly tied to love and passion.

It’s a popular color in website design, though, due to its boldness, it’s most commonly used as an accent color. With that said, there’s no reason why it can’t take on a more prominent role in a website’s overall design, as demonstrated in these twenty-five awesome red websites.


Intensity in Ten Cities


Big Spaceship


Grafik


jonwallacedesign


Codebutton.com


Chrome


Khai Liew


Thierry Castel


Hemlock


Sonze Design Studio


Host Riser


Youth Against Sudoku


Take the Walk


Remood


Waider Mediendesign


Liga Retro


Saforian


Red Relevant


Coalmarch Productions


Avalon Business Advice


Mirror Communications


Blogsessive


New to York


Associate


Truf Creative

You Almost Might Like



Quick Tip: Loop Through Folders with PHP’s Glob()

Quick Tip: Loop Through Folders with PHP’s Glob()

Are you still using opendir() to loop through folders in PHP? Doesn’t that require a lot of repetitive code everytime you want to search a folder? Luckily, PHP’s glob() is a much smarter solution.


Introduction

Here’s an example of echoing out some information from a folder, using the traditional opendir() function.


	$dir = "/etc/php5/";

	// Open a known directory, and proceed to read its contents
	if (is_dir($dir))
	{

		if ($dh = opendir($dir))
		{

			while (($file = readdir($dh)) !== false)
			{
				echo "filename: $file : filetype: " . filetype($dir . $file) . "\n";
			}

			closedir($dh);

		}

	}

That should look somewhat familiar. We can massively shorten the code above with:

	$dir = "/etc/php5/*";

	// Open a known directory, and proceed to read its contents
	foreach(glob($dir) as $file)
	{
		echo "filename: $file : filetype: " . filetype($file) . "<br />";
	}

Isn’t that much easier? Eager to learn how the method works? If yes, then let’s get on with it.

glob() supports a total of two arguments, with the second argument being optional. The first argument is the path to the folder, however, it’s a bit more powerful than that.


Step 1. The First Argument

This first argument supports a pattern. This means that you can limit the search to specific filetypes or even multiple directories at the same time by using multiple asterixes “*”. Let’s assume that you have a website that allows users to upload images (just because I read this). Each user has his/her own folder within the folder “userImages.” Inside these folder are two additional folders, called “HD” and “TN,” for high definition (full-sized) images, and for thumbnails. Let’s imagine that you want to loop through all your users’ “TN” folders and print the filenames. This would require a relatively large snippet of code if you were to use open_dir(); however, with glob(), it’s easy.

	foreach(glob('userImages/*/TN/*') as $image)
	{
		echo "Filename: " . $image . "<br />";
	}

This will search userImages/any/TN/any and will return a list of the files that match the pattern.

	Filename: userImages/username1/TN/test.jpg
	Filename: userImages/username1/TN/test3.jpg
	Filename: userImages/username1/TN/test5.png
	Filename: userImages/username2/TN/subfolder
	Filename: userImages/username2/TN/test2.jpg
	Filename: userImages/username2/TN/test4.gif
	Filename: userImages/username3/TN/styles.css

We can even take things a step further, and be more specific by including a file format in our foreach statement:

	foreach(glob('userImages/*/TN/*.jpg') as $image)
	{
		echo "Filename: " . $image . "<br />";
	}

Now, this will only return Jpegs.

	Filename: userImages/username1/TN/test.jpg
	Filename: userImages/username1/TN/test3.jpg
	Filename: userImages/username2/TN/test2.jpg

It gets even better. What if, for instance, you require Jpegs, but also Gifs; nothing else? Or what if you want to print only folder names? This is where the second argument comes into play.


Step 2. The Second Argument

The second argument is, as mentioned previously, optional. It does, however, provide a very nice set of optional flags. These will allow you to change the way your glob() behaves.

  • GLOB_MARK: Adds a slash to each directory returned
  • GLOB_NOSORT: Return files as they appear in the directory (no sorting)
  • GLOB_NOCHECK: Return the search pattern if no files matching it were found
  • GLOB_NOESCAPE: Backslashes do not quote metacharacters
  • GLOB_BRACE: Expands {a,b,c} to match ‘a’, ‘b’, or ‘c’
  • GLOB_ONLYDIR: Return only directory entries which match the pattern
  • GLOB_ERR: Stop on read errors (like unreadable directories), by default errors are ignored

As you see, the potential requirements that we noted at the end of Step 1 can easily be fixed with GLOB_BRACE:

	foreach(glob('userImages/*/TN/{*.jpg,*.gif}', GLOB_BRACE) as $image)
	{
		echo "Filename: " . $image . "<br />";
	}

which will return this:

	Filename: userImages/username1/TN/test.jpg
	Filename: userImages/username1/TN/test3.jpg
	Filename: userImages/username2/TN/test2.jpg
	Filename: userImages/username2/TN/test4.gif

If we wish to only print subfolder names, we could use GLOB_ONLYDIR:

	foreach(glob('userImages/*/TN/*', GLOB_ONLYDIR) as $image)
	{
		echo "Filename: " . $image . "<br />";
	}

which will print:

	Filename: userImages/username2/TN/subfolder

Conclusion and One More Example

This method has been available since PHP 4.3, however, it’s not used very often, strangely. I didn’t learn it until quite late myself. Now, I often use glob() when loading plugins into my framework:

	foreach(glob('includes/plugins/*.php') as $plugin)
	{
		include_once($plugin);
	}

That’s all; I hope you enjoyed this quick tip, and let me know if you have any questions!



Make Our Browsergame Better

Make Our Browsergame Better

We have a Browsergame. Its similar to Ogame and based on the open source from a game calles XNova.

We need a Team that want to work with us more than only 1 project.
We need a Team which knows php html java and stuff like this.
Knowlage about graphikdesign will be good too.

How is the procedere?

Well,the “winner” of this project will become a excel list with a “to do list”
In this list the there are few projects where u can write the the needet time and the cost.

U or we provide a testserver where we can test the change things.

More details per mail.

Web Developer

Web Developer

I need a web designer who is versed in css, java script, php 5, xml and flash cs4. I need a registration, log in, search engine and resource database created. I need a flash photo gallery that can be uploaded and its attributes changed with a xml file as well as a drop down navigation menu created and our company logo fine-tuned. I am starting off with it and i need the quotes to be fair.

If agreed we can start with it as soon as possible.

Let me know the details you need to clarify

Thank you

Affiliate Programs

Affiliate Programs

I am a full affiliate, and I need to customize some process /html template, landing pages, scrips,etc .The “scope” is:

1.Edit the original Landing Page, the idea is build my own list!
2.Submit all package to my server(landing page, sales page, etc)
3.Download all “Silver Bullets” and submit to my server
4.Make Sure the sales pages get my clickbank ID
5.Each product that i’ll choose have to be submit it to my hosgator account

I ‘m gonna choose 5 products from the list, and also i’ll buy 5 domains.

All information come from this website:

http://affiliatesilverbullet.com/members.php?m=bl&baw=1

Please check out the website before bid

Don’t Pay Attention about “promo tools” ,this is my duty!

PD:Spanish speaking is required!

This project is”urgent”, The product launch is On april 29th.

Student Exercise Book

Student Exercise Book

To create student workbook for memory skill, mind mapping and other learning skill to improve student (7-15 years old) academic result. We need a lesson plan of 50 hours. We will provide you with an sample.

You need to write objective, instruction, create exercises for each hour lesson plan.

You need to do some research with the above titles and preferably with some teaching manual experience. Both creative and logical thinking is required.

Let me know if you are interested and we discuss further.
Thanks.

Multi Game – Adobe Stratus

Multi Game – Adobe Stratus

I need a Multiplayer game called Bubble trouble done, for 2 players.
Here is the game example :
http://www.miniclip.com/games/bubble-trouble/en/

On my website, people chat together, a bit like on MSN, and they should be able to invite eachothers to play this game together.

The connection between the players needs to be with Adobe Stratus, which allows P2P so my server doesn’t have much to do.

The high score for each teams will be saved in the DB.

You should use As3 for the game, with Flash CS4 or Flex.

You can develop the game multiplayer using Stratus, then when the game is developed we can implement it probably easily on my website with my other programmer.

Thanks

Copy Careercabin Site 2

Copy Careercabin Site 2

This project is to copy the site and functionality of careercabin.com

Use EXACT same graphics…this project is for the coding, not graphics!

This site has a
1. front end
2. employer registration
3. employer login
4. post a job
5. job details
6. apply now (record ip of applicant)
7. search jobs
8. ability to send list of jobs via rss feed
9. backend
10. ability to export job applicants data (date/time, ip, first name, last name, email, phone) as csv format

It should be done in PHP (instead of asp).

Forced Matrix System

Forced Matrix System

We are looking for a skilled programmer to complete the project.

We require a 2×2 forced matrix system. We need the frontend website to be developed. Members will be required to make a one-time purchase on signup and will cycle once the matrix is filled. This will be a follow-me system. Members will need to login to their area to check their status and compensation payments. Once signed up, members will have a replicated website from which they will sell products.

The site will need to be inegrated with Alertpay.

We will be looking for a developer/team with experience in this type of system. Please do not bid if you have no experience. Thanks.

The site should be very professional and the coding should be logical and easy to maintain/update should any changes to the system be required.

Payment will be made in escrow as soon as a developer is selected.

Editor For Magazine Articles

Editor For Magazine Articles

I have a Health magazine and I am looking for an editor that can edit my articles. They will need to be edited down (around 900-1500 words) to character or increased, and make the article easy to read. I provide all the details and a rough draft (outlined). Some will be rewrites. I have created a video to give more detail. Please view before bidding: http://www.youtube.com/watch?v=Z46DQYWTBWk

I am looking for a Long Term editor, so price and quality are KEY! There will be a 5-8 articles per month.

Please Bid for 3 Articles and the timeframe for completion.

I have attached an article for you to edit for a sample of your work.

Any PM will be deleted and banned if there is NO BID!!

Requirements:

Proficient in English
Able to edit in easy to read (conversation type)
Editor must be quick to respond to emails, IMs, Skype.