Jump to content

duclet

Members
  • Posts

    140
  • Joined

  • Last visited

    Never

Contact Methods

  • Website URL
    http://www.tiger-inc.com

Profile Information

  • Gender
    Not Telling

duclet's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. I think you should re-read your post and notice that your logic is flawed. You are exactly right, consumer demands is the driving force of everything. Business people in order to actually make a profit, needs to appease these people, especially when they own such a large portion of the market. As you say, we still need to be moving forward though and use the new technologies and such. We can't just ignore all of these people with IE by using truly standardize CSS that Opera and Firefox supports. While at the same time, we can't just keep using old invalid CSS just for IE because they own the market while ignoring the more compliant browsers. We have to have support for both at the very least. While most developers know the limitation of the current browsers, most high up people don't or does not care. They see something in an image and they want what you code to look exactly like that by the pixel. Again, and I am wondering if you people actually read my post or you are just skimming, but as I have said, I have nothing against CSS. I love CSS in fact and that is what I use to build my web site. Take a look at it and you'll see it is not using tables and only CSS (well, mostly). I always encourage people to use CSS to style their web site and keep their code clean. But at the same time, I want people to know that when you start to build your website with purely CSS, known that there are going to be time when you are sitting there cursing at IE or some other browser because it is not behaving as you want it to. CSS is the present and the future and clearly, more developers should start to use it to style their web site instead of using tables and the such. However, until all the web browsers are truly compliant with the standards set by W3C, be ready for some pain.
  2. Unless it is your own personal web site and you don't care about your visitors, then you have to make your stuff cross browser compatible. Working at companies whose web sites gets millions and millions of people visiting each day force you to make your code cross browser. And yes, that also means dealing with structures written by someone else. Heck, I have to make all of my code compatible with Firefox, IE7, IE6, Safari, and Opera with IE8 looming.
  3. Clearly you people have not done anything truly complicated with CSS. Nine months? Try 3 years! Yes, CSS is great and I love it myself but to say it is easily is simply foolish.
  4. Easier? You must not have work with CSS in a long time or don't care about cross browser compatibility. While I agree people should start to use CSS, the fact is, it is not greatly supported. Too many times you get things to work correctly in one browser and it doesn't work in another (namely IE). Though for you, get rid of the tables and use divs with relatively positioning should do the trick.
  5. It is very strange to see tables with CSS. Anyway, the problem is the margin and/or padding. Just set padding & margin to 0 and that should fix the probelm.
  6. Exactly right. I can't believe I missed that too.
  7. I think for this particular case, you are better off using $_GET or $_POST. Using $_SESSION has the drawn back of unexpected behavior if there is a page refresh and data lingering while it shouldn't. You should be able to do something like the following: $myarray = array(...something data...); $myarrayasstring = htmlentities(serialize($myarray)); <a href="somelink.php?arraydata=<?= $myarrayasstring; ?>">Send</a> ... $data = unserialize(htmlentity_decode($_GET['arraydata'])); I might have misspelled some of the function names but you get the idea.
  8. Unless it is really simple, I always prefer to keep the HTML separate from the PHP. Using scripts such as Smarty is my preferred choice. It is slower on performance though but it is barely noticeable.
  9. I can't see what is wrong with the code though I did clean it up a little: function getwchar($uid) { $query = "SELECT * FROM characters where id='$uid'"; $result = mysql_query($query) or die (mysql_error()); $wchar = NULL; while($row = mysql_fetch_assoc($result)) { if($row['wchar'] = 'quinary') { header("Location: charerror.php"); } elseif($row['wchar'] = 'quaternary') { $wchar = 'quinary'; } elseif($row['wchar'] = 'tertiary') { $wchar = 'quaternary'; } elseif($row['wchar'] = 'secondary') { $wchar = 'tertiary'; } elseif($row['wchar'] = 'primary') { $wchar = 'secondary'; } else { $wchar = 'primary'; } } return $wchar; } The only thing I can think of is that your query is only returning one row of data.
  10. It is stopping at the first one because $row[wchar] is probably equaled to 'quinary'. The function header with the Location string will pretty much stop the execution of the script and redirect you to a different page.
  11. It is php.ini not php.info. Anyway, there are plenty of host out there. The one I am currently using is Dreamhost. I have been pretty happy with them though some of their customers has to suffer for over a couple of weeks as they were moving their data centers. Anyway, signup at http://www.dreamhost.com if you want. Use this promo code to save $25: DUCPROMO. By the way, not only can you editing your php.ini file, but you can install your own customized version of PHP if you wanted with them.
  12. First of all, did you set up the table to autoincrement?
  13. My philosophy on things since that unless you know for a fact that you will be including a file more than once, I always use the *_once functions. I also tend to use the require* functions since I want to see a fatal error if a file is missing since to date, all of my includes are "require"d.
  14. You don't really need a function. Couldn't you do something like the following: <?php $original_array = ("12345", "56789", "KL5-1231231","KL5-1230502"); $array1 = array(); $array2 = array(); foreach($original_array as $item) { if(isset($item[6])) { $array1[] = $item; } else { $array2[] = $item; } } ?> Of course you can use strlen($item) < 6 instead of what I have in the if statement but I like my way since it is a little faster.
  15. Though I don't recommend doing this, you can try something like the following: <?php ob_start(); include 'update.php'; ob_end_clean(); // The rest of your update2.php file ?> This will include the code of update.php but because of the output buffer, the output of update.php won't be shown. We use ob_en_clean to terminate the output buffer without outputting anything.
×
×
  • 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.