Click here to Skip to main content
15,886,873 members
Home / Discussions / Linux, Apache, MySQL, PHP
   

Linux, Apache, MySQL, PHP

 
GeneralRe: Little help with my php code pls Pin
cjoki12-Oct-09 6:12
cjoki12-Oct-09 6:12 
GeneralRe: Little help with my php code pls Pin
fly90412-Oct-09 6:54
fly90412-Oct-09 6:54 
GeneralRe: Little help with my php code pls [modified] Pin
cjoki12-Oct-09 7:54
cjoki12-Oct-09 7:54 
GeneralRe: Little help with my php code pls Pin
fly90412-Oct-09 9:01
fly90412-Oct-09 9:01 
GeneralRe: Little help with my php code pls Pin
cjoki12-Oct-09 9:34
cjoki12-Oct-09 9:34 
GeneralRe: Little help with my php code pls Pin
fly90412-Oct-09 10:22
fly90412-Oct-09 10:22 
GeneralRe: Little help with my php code pls [modified] Pin
cjoki12-Oct-09 11:03
cjoki12-Oct-09 11:03 
GeneralRe: Little help with my php code pls Pin
fly90412-Oct-09 11:50
fly90412-Oct-09 11:50 
cjoki wrote:
Currently I am updating my js knowledge to the current standards of code separation...(i.e.: removing things like ...to and js adding the event logic at the end page load.).


You get a thumbs up Thumbs Up | :thumbsup: That's the kind of thing I enjoy doing. Have a look at using jQuery. jQuery could do what you want with a single line.
$(document).ready(function() {
    $('#btn').click(some_function);
});
(Added new lines to make it more readable.)



cjoki wrote:
I am also contemplating an issue of external (multiple) css file loads vs style tags with css loaded based on page need using php code logic. I suspect in projects with a large number css rules can be refined to reduce the file size (sent to the browser) by send only the needed rules without the need for a larger number of file reads (split css files). But this flies in the face of separation of style from html...and I need to test, well I first need to figure out how I could test.


I was playing around with this the other day.

For performance, minimizing your js files, using a tool like this[^], greatly improves page load times. The same applies for css file. Loading multiple small css files is slower than loading one big css file. There is a css compressor[^] as well.

Note: It's only worth minimizing files on release versions.

A good tool for testing page load time is the Firebug addon[^] for Firefox. It has a tab called 'NET' which shows you how long everything takes to load. It also debugs JS which is very useful and shows the DOM while JS is changing it.

Hope that helps Smile | :)

If at first you don't succeed, you're not Chuck Norris.

GeneralRe: Little help with my php code pls Pin
cjoki12-Oct-09 12:20
cjoki12-Oct-09 12:20 
GeneralRe: Little help with my php code pls Pin
fly90412-Oct-09 12:38
fly90412-Oct-09 12:38 
GeneralRe: Little help with my php code pls Pin
cjoki13-Oct-09 5:05
cjoki13-Oct-09 5:05 
Questioninstallation Pin
WilliamSimon8-Oct-09 12:07
WilliamSimon8-Oct-09 12:07 
Questioninstallation Pin
thangvel8-Oct-09 11:54
thangvel8-Oct-09 11:54 
AnswerRe: installation Pin
Richard MacCutchan14-Oct-09 6:07
mveRichard MacCutchan14-Oct-09 6:07 
AnswerRe: installation Pin
Iranian MM7-Sep-11 9:40
Iranian MM7-Sep-11 9:40 
Questiondownload php code Pin
udch7-Oct-09 1:24
udch7-Oct-09 1:24 
AnswerRe: download php code Pin
EliottA7-Oct-09 2:41
EliottA7-Oct-09 2:41 
QuestionI need some help Pin
robertbarzyk6-Oct-09 12:55
robertbarzyk6-Oct-09 12:55 
AnswerRe: I need some help Pin
Marc Firth6-Oct-09 22:02
Marc Firth6-Oct-09 22:02 
AnswerRe: I need some help Pin
fly9047-Oct-09 5:01
fly9047-Oct-09 5:01 
Questionfetch data Pin
udch6-Oct-09 3:18
udch6-Oct-09 3:18 
AnswerRe: fetch data Pin
cjoki12-Oct-09 5:41
cjoki12-Oct-09 5:41 
GeneralRe: fetch data Pin
udch19-Oct-09 9:32
udch19-Oct-09 9:32 
QuestionPython Tutorials?? Pin
TGeist5-Oct-09 17:44
TGeist5-Oct-09 17:44 
AnswerRe: Python Tutorials?? Pin
ClockEndGooner26-Oct-09 9:54
ClockEndGooner26-Oct-09 9:54 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.