Like my post perhaps?

I did! Thumbs up on all your 2 replies and on John_191's, either before I replied or right after, don't remember.

Thank you for the replies! Intersection definitely did the trick. Ended up going with

if not (product.color & TARGET_COLOR).empty?

What about if I just needed it to lazy match? Would any? be better? What would that look like?

Are you sure you mean Photoshop and not Dreamweaver? You can't edit a website in Photoshop, it's an image editor. Dreamweaver is a web development editor: you can open your site resources in it, view them in design view if desired, and edit them there. Though honestly, I find it less professional to use DW.

Photoshop should be used for designing your site, such as layout and graphics. But it's not a replacement for HTML & CSS. It's a way to visualize what you're going to code in HTML & CSS, and extract the graphics you're going to use.

Thanks bro, I took a class in the basics of html over the summer but before that I had no experience in programming whatsoever. So no I know its not the best, Im learning on the go. But main nav for the menu, got it. Thanks. Hey, what do you mean by self-terminationg DIVs?

For the menu, yes, use links (<a href> elements). Often these are nested inside of unordered lists:

<ul id="nav">
    <li><a href="/a-link.html">Home</a></li>
    <li><a href="/another-link.html">About</a></li>
    ...etc...
</ul>

As for self-closing divs, I was referring to:

<div id="text-align" style="text-align:center;"/>

This really depends on what your DOCTYPE is. In XHTML if you put a /> at the end of a tag it is essentially the same as doing <tag></tag>. This makes little sense for DIVs because they're usually used to contain other elements. In this case the code essentially creates a DIV called text-align which provides center alignment for text, but then immediately closes itself, which accomplishes nothing.

Good topic. I haven't worked on too many big "from scratch" projects so I'm looking forward to some interesting responses here.
For me, the first item is figuring out what the project is about, and if there's a cost-effective platform out there that I can use as a framework. This way I don't have to reinvent the wheel; oftentimes it's easy for the client to learn to use, and they're happy 'cause they don't have to pay me for a custom CMS. WordPress has often been my weapon of choice. I'm also trying to learn CakePHP.
If the project DOES have to be from scratch, I'd actually say that the database is one of the first things I'll work on. You need to know what kind of information you want to store and relay before you can decide how you want to present it. Plus I think this helps because while you're already building the DB you can insert dummy content for testing later on. If the client already has the schema figured out and has provided you with a site design based on it, awesome.

Once I have the design I prefer to break it down into its HTML structure. I usually do this by hand-coding. This way I'm very familiar with the elements I may need to reference in CSS and JS. Then yes, slice and dice in PS and start figuring out your CSS. Again, I prefer hand-coding.

For the rest I'd say you're pretty spot on ...

Use jquery's .css() to get the current value of a style property for an element. Similarly, adjusting a style with .css() will apply it to the element as an inline style.
http://jsfiddle.net/QSg6k/1/

silverdust commented: Great! Thanks Evolution! +0

This is really a matter for your legal department... Many companies will have clauses in their developers' contracts stating that any software developed while an employee of the company/organization is owned by the company/organization. So if a new developer comes in and then tries to steal the code, you can sue their pants off.

Of course, this all probably depends on the laws of the country, state, and maybe even the city you live in.

Try using Y-M-D format, see if that works?

SELECT startDateTime, endDateTime FROM jobs WHERE startDateTime BETWEEN '2013-11-19' AND '2013-11-20'

My only additional advice is to use this to set classes for your TDs instead. This way you can change the actual appearance in your stylesheet.

@Gaetane don't forget session_start() at the top of the page!

First off, you've created 9 <th>s but have only 8 fields you're pulling from the DB. You're not outputting anything to your Generate Bill column.

My recommendation is rather than a foreach loop for outputting your fields, do it the long way. I.e.,

// Inside your loop...
print "<tr>\n";
print "\t<td>$a_row['slno']</td>\n";
print "\t<td>$a_row['refno']</td>\n";
//etc., etc. Don't forget your Generate Bill column!
print "</tr>\n";

Now it's also easier to follow pritaeas' advice. Decide which column in your table you want to contain the clickable link to go to the View page. You might use the Serial No column, for example.

// replace the "slno" line I put above with:
print "\t<td><a href='/view.php?id=$a_row['slno']'>$a_row['slno']</a></td>\n";

That done, you create a script called view.php and add a line with:

if(isset($_GET['id'])) {
    $id = (num) mysql_real_escape_string($_GET['id']);
    // Add to code to search your database for an entry with this serial number
}

Where is your data for $_GET['location'] coming from? Your form submits via POST (line 1), and it doesn't have any field named "location". You should change line 4 of the form to:

<input type="text" name="location" id="location" class="form-control" placeholder="90001" required>

Then in zip-checker.php, change $_GET to $_POST.

One other tip. No reason to use the $location variable, just drop the header() function calls right into the first if-else blocks.

Just to add to the above, there's a typo in your function. It's mysqli_real_escape_string, not mysqli_real_excape_string (yours has an "x" instead of an "s").

Atli commented: Nice catch. Totally missed that :) +8

For completeness, the HTML5 docs allow "Phrasing content" as children of <legend>. The span tag is listed as such, so yes it's valid.

I've not used this myself, but I think you need to look into JavaScript's unload, onunload, and onbeforeunload events.

I have to agree with paulkd, are the checkboxes really necessary? Can't you just check if the value in the input box is not empty, and greater than 0?

Also, please provide your HTML and form processing code so we can see where you're having a problem.

You should review the validity of your HTML. While it might not solve the issue in this case, it often helps ruling out other items. Try using http://validator.w3.org. Some errors I see of the bat:

A) Your TEXTAREA tags are self-terminating, yet are followed up with a closing tag. Textareas should not self-terminate. Line 18:

<textarea rows=\"5\" Cols=\"22\" name=\"VacancyDescription\" style=\"display: inline-block; margin-left:10px;\"/> </textarea>

PHP would print this out as

<textarea rows="5" Cols="22" name="VacancyDescription" style="display: inline-block; margin-left:10px;"/> </textarea>
                                                                                                       ^ Note this slash. That's a problem.

B) You should not have more than one occurrence of an id on a page. If the value needs to be used more than once, you should be using a class. So instead of id="window", id="title_bar", or id="box", use class="window", class="title_bar", class="box". Do the same for any other such examples.

C) As mentioned above, in you open DIVs on lines 63 and 66, but on lines 83 and 84 there are a total of four closing </div> tags. This probably ends up closing 2 container divs, which would throw off your whole layout.

Just a note. For debugging something like this it's also useful to see the container DIVs and their CSS, considering your usage of widths, borders, margins and floats for layout.

Unimportant commented: Solid post +4

Sorry, I'm missing something. I don't get how OP was hijacking the form at the top. The "reload" function only happens when you change the SELECT. It seems to me like the point is that on reload it correctly updates the prod_price field with the value from the db. Then the form gets submitted to updprod.php (as opposed to upd_prod.php), where I assume the price is updated in the DB.

@sanbhu2105, what happened to your <form>, and more importantly, the <select> element?

diafol commented: good shout +14

I used to use https://gomockingbird.com/ back when it was in beta. I was pretty happy with it.

Add position: relative; to ul.products li (Line 21).
Then if you add an <img> with class "new" to the appropriate ul.products li element, you can assign position: absolute to img.new, and push it around with top:, right, bottom, or left as desired.

See jsFiddle for example: http://jsfiddle.net/LEt7Y/ (Note I used a <p> element, you can of course replace with an <img>)

You're looking for addClass and removeClass

While PHP can print out JavaScript, basic JavaScript cannot interact with PHP. To do so you need to use AJAX (Asynchornous JavaScript and XML), which allows JavaScript requests a file from the server without reloading the current page.

To solve your problem, read up on AJAX and how to use it to call PHP files. Once you have some code together come back here if you have any problems.

First of all, you should get familiarized with mysql_fetch_array, since mysql_fetch_assoc is getting dropped in php5...

This statement is misleading. The reason mysql_fetch_assoc() is getting dropped is because the mysql extension is getting dropped. So to "get familiarized" with mysql_fetch_array() will not help. Instead use mysqli_fetch_assoc() with the mysqli extension (or even better, do it the OOP way!).

ndeniche commented: thanks. Didn't know this +10
diafol commented: agreed +14

In your first code snippet there's no DB connection before line 6, where you run your first query.

Write your own form and we'll help you out where we can. We're not going to write code for you from scratch. Especially for an advanced form such as this one.

pixelsoul commented: True dat! +7

So something like this?

I already gave you a solution in the second reply to this thread...

Update your button HTML:

<button type="button" onclick="return ChangeColor(this)">Red</button> 
<button type="button" onclick="return ChangeColor(this)">Blue</button>
<button type="button" onclick="return ChangeColor(this)">Black</button>

Then your JS:

function ChangeColor(theButton) {
    document.getElementById('test').style.color = theButton.innerHTML;
}

The correct function is is_null().

Change line 5 to:

<select name="community" id="select7" onchange="javascript:if(this.value=='other')window.location.href='REDIRECT/PATH/HERE';">

If you need this to be more scalable, you can make it a JS function instead.

EDIT: Good catch, TonyG. Those <label> tags don't belong there, and while the onchange will handle redirects, submitting won't work without <form> tags.

Seriously, just take this one step at a time. This apache installation stuff is nonsense to you right now.

Learn HTML and CSS. As stated previously, and as you know by now, you don't need anything except a browser and a text editor. Practice and get good at both. Learn to use developer tools like Firebug or Chrome dev tools to debug/test updates to your pages. You need to be able to solve problems that crop up on the frontend.

After this, decide where you want to go next. I went to PHP (soon followed by MySQL) right after, but if I could go back I would have done JavaScript next. If you read books/tuts about rich web apps with PHP, and you don't understand JavaScript and AJAX, a lot of stuff can be confusing. I think it's better to learn the foundational client-side languages first (HTML, CSS, JS).

Once you're ready to move to server-side, the cheapest way is to install a server on your own computer. I use XAMPP, it's super easy to install and in no time you can have an Apache server up and running with PHP and MySQL. Then you just do your dev in the htdocs folder, point your browser to http://localhost/ , and see the fruits of your labor...

somjit{} commented: its great when people share their experience. thanks for this :) +3