Jump to content

cssfreakie

Staff Alumni
  • Posts

    1,674
  • Joined

  • Last visited

Everything posted by cssfreakie

  1. Hi thorpe, Small question here so i just reopend the thread hope that is not a problem, I just googled a bit on what you said "to place javascript at the bottom" and ended up at: http://developer.yahoo.com/performance/rules.html and they recommend that too, and explain why. So i thought lets look at their source code, and what i see them doing is putting javascript even below the </html> tag but also some rigth above </body> as you said. Is there a reason why they split it up like that, or are there some things that must be placed in the body as javascript? it's nothing urgent, but i was just eager to know Thanks anyways for the great tip. the page indeed loads faster.
  2. That's great advise! And i understand it now. Only the stuff exist after it has been read. thanks i will never do this wrong again That ajax is really fun to play with I think i am going to make a chat box with it
  3. I hope you do realize that you just posted your complete stylesheet, and that no one is going to read through that. As for any css topic i recomend you host this somewhere so we have a visual reference and by using a nice tools such as firebug (for firefox) we can immediately see what lines in your stylesheet you mean. Anyway i don't see the image in your html mark-up, so that would not be the reason why your div is not expanding. (a background image in css wont either) what you could do is give the div a min-width: Something like this: div#sample04{ min-width: 500px; } There are some free hosting companies that offer you php mysql and everything for free. So you can upload it there and show us. that way it is much easier to help you out on css. I use this one: http://www.000webhost.com/ Although this is an okay approach for a first few websites, i rather make my own since the naming of id's and classes is often terrible. for instnace sample4 ? what does that mean... i rather use #header #left #mid #right #footer etc
  4. lol i put the <script below the targeted div, and now it works... I did this as a complete uneducated guess. Anyone want to enlight me why this is? I always thought the script is read from top to bottom.
  5. okay cool, thanks a lot Thorpe than this one is solved i guess cheers!
  6. oh crap sorry thorpe i was pretty confused at the moment of writing The thing is I expect the index.php to retieve the stuff from script.php ones someone presses the button with id #load_basic. After than the stuff from script.php should end up in side the div with id #result. I thought i did a good job, but for some reason the script.php is not loaded. Could it maybe have something to do with the position of the <script> should i maybe place it below the targeted div?
  7. nice one, mark it solved, saves others time reading
  8. yeah sure. <script type="text/javascript"> $.ajaxSetup ({ cache: false }); var ajax_load = "<img class='loading' src='images/wait.gif' alt='loading...' />"; // load() functions var loadUrl = "script.php"; $("#load_basic").click(function spitOut(){ $("#result").html(ajax_load).load(loadUrl); // <<<< that is the .load which results ina warning setTimeout(function(){spitOut();},5000); //re run it }); </script> edit: i should have said .load instead of onload
  9. looks pretty good, but i would remove the border of the images, (also better align them one is popping out) also the horizontal menu, choose a different :hover color and maybe even replace the blue in a more bright tint or maybe even white. rest looks decent, enough air to breath for the content
  10. not at all, nowadays analyst (off financial institutions) are much better capable of calculating the value of companies. Internet is serious business and it will always be that way.
  11. Hi crmamx, As for your design, i just checked and indeed frames and scrollbar's other than on the normal position are not very nice looking. I would rather go for a 2 column layout, just like a postal card, where 2/3th is the main topic 1/3 is a column for additional modules like latest news events calender etc. And since you are in the sky stuff, get one nice picture and place it as background. Just a simple layout, keep it simple choose no more than 4 colors apart from black and white. choose the right font. and that's it. see attachement for maybe some inspiration. its easy to make with css and a little html. And you don't need costly photoshop. Gimp and Inkscape are free. (last one is easiest to learn) good luck! -edit the background photo i used is just a very low quality google supplied one, but you get the idea [attachment deleted by admin]
  12. Hi all, i am running netbeans and i got a little warning mark on the .onload function in a little script i have. .onload is part of the jquery framework. Does anyone know what i should be using instead or any other advise? Sorry for all my asking but i am a complete noob in javascript. [attachment deleted by admin]
  13. could you maybe show what you mean by that, and what was the solution. sorry for asking but i am pretty eager to learn this
  14. Hi all i just read a tutorial about jquery and ajax, and i am allready stuck on the very first exampleI just can't see what i do wrong. Any help is appreciated: index.php <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> <link rel="stylesheet" type="text/css" href="css/mediabox.css" /> <script type="text/javascript" src="//ajax.googleapis.com/ajax/libs/jquery/1.5.0/jquery.min.js"></script> <script type="text/javascript"> $.ajaxSetup ({ cache: false }); var ajax_load = "<img class='loading' src='img/load.gif' alt='loading...' />"; // load() functions var loadUrl = "script.php"; $("#load_basic").click(function(){ $("#result").html(ajax_load).load(loadUrl); }); </script> <title>lalala</title> </head> <body> <div class="functions" id="result"> </div> <input type="submit" id="load_basic" value="load()" /> </body> </html> script.php <?php echo 'moo says the cow'; ?> Am i missing something obvious? or violating a best practise? this is really mindgoggling me :'( This is probbaly because i never use javascript
  15. Uhm this topic is marked solved, but i don't see a solution, please post it
  16. i have no idea how to do that, but I do know is that most people love it when you post your code in [code]tags
  17. no read that last sentence, i have a lot of difficulty deciphering that. Anyways, since i have no clue what your last question is. Most websites have a markup like this and what they do is center the wrapper div. So in other words They wrap up all they want in 1 div (in this case named wrapper) and apply the margin:0 auto; to it. <body> <div id=wrapper> <div id=header></div> <div id=left></div> <div id=mid></div> <div id=right></div> <div id=footer></div> </div> </body> if you have questions let me know
  18. crap as in unneeded styles. I have seen quite a lot of templates that style there css pretty redundant. When you just use your own stylesheet, you have much more control. besides that it's much more fun to do it yourself.
  19. have you got it online somewhere so i can have a look? You don't have special properties for the tables set I assume you mean the text in the table is big right?? Pretty unclear in your question. besides that we don't know what you have in those 3 css files... just post this online on some cheap free host works much faster
  20. well i should first of all, try to get a form working without any javascript. javascript can be disabled by the enduser (clientside) so it should only be used for extra awesomeness That said, hereunder you find a nice (self referencing) form with limited validation that shows the post data on the next page load. you can use another file, just fill in the file name at the form action. If you like to use submitted variables on other pages than the form action is pointing at, have a read about sessions. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en" > <head> <meta http-equiv="Content-type" content="text/html; charset=utf-8" /> <meta http-equiv="Content-language" content="en" /> <title>my form</title> </head> <body> <?php $error_messages = array(); if(isset($_POST['submit'])){ //check if pressed submit if(!empty($_POST['firstname'])&&!empty($_POST['lastname'])&&!empty($_POST['age'])){//no field may be empty echo 'you succesfully submited post data'; }else{//if pressed submit but fields are empty $error_messages[]= 'you left fields empty'; } }else{// if not not pressed submit $error_messages[]= 'please fill in the form'; } ?> <form id="myform" action="" method="post"> <ul style="text-align: right; float:left; list-style: none;"> <li><label for="firstname">firstname:</label><input id="firstname" type="text" name="firstname" value="<?php echo isset($_POST['firstname'])? $_POST['firstname']: '' ;?>" /></li> <li><label for="lastname">lastname:</label><input id="lastname" type="text" name="lastname" value="<?php echo isset($_POST['lastname'])? $_POST['lastname']: '' ;?>" /></li> <li><label for="age">age:</label><input id="age" type="text" name="age" value="<?php echo isset($_POST['age'])? $_POST['age']: '' ;?>" /></li> <li><input type="submit" value="submit" name="submit" /></li> </ul> </form> <p id="errormessages"><?php if (!empty($error_messages)){ //if there are errors echo implode('<br />', $error_messages); //output error messages array } ?></p> </body> </html> hope this helps p.s. in real life i would have not used inline css -edit: i made a little change i had the name of the submit button set to 'enter' I changed it to submit otherwise nothing would work
  21. i would make your own really copy and pasting stuff brings along alot of crap often.
  22. I would use an ID for that div really instead of a class. anyways this is what you can do div#my-centered-div{ margin:0 auto; width:960px; /*just some width */ } for IE6 and lower use div#my-centered-div{ text-align:center; } Hope this helps
  23. Thanks alot neil for this detailed response. I agree with you that a background process would be ideal. I will certainly have a look into that. But i still need to learn alot. So i put that on my to do list. Would you mind if i bother you ones i made a complete script with that exec() functionality in it and the flag to the database just to have a quick look. I think i now have a better Idea of what you meant and i will try to work it out as far as my knowledge reaches. Anyways thanks alot for your reply and help and also Crayon thanks alot for your help. Cheers! -edit i know swiftmailer, but I have difficulty remembering things and understanding things if i don't know the technique behind it So i am not stubborn to invent the wheel but want to learn how it all works
×
×
  • 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.