Hi all,
Quick question... I have a class that is over 1200 lines of code and 50
KB in size. This file does not display any html, it is just included
and after I call all the necessary functions, I save the data and
display it on my output page.
Here is my confusion - to the best of my understanding, since php is
server side, this file should never be "transferre d" to the client,
correct? In other words, whether my class is 100 lines or 10,000 lines,
it shouldn't have any affect on my bandwidth or transfer rate should it?
Please correct me if I am wrong, but I have been operating under the
assumption that the only thing that gets transferred to the client is
the php file after it has been parsed for all html formatting, and the
size of this final product is what affects the speed of transfer.
Thanks in advance. 3 2314
That's exact, php parse the file and the web server give the result to the
client... you 1200 lines will never leave the server.
Dae
"Marcus" <Ju********@aol .com> wrote in message
news:JI******** ***********@new ssvr19.news.pro digy.com... Hi all,
Quick question... I have a class that is over 1200 lines of code and 50 KB in size. This file does not display any html, it is just included and after I call all the necessary functions, I save the data and display it on my output page.
Here is my confusion - to the best of my understanding, since php is server side, this file should never be "transferre d" to the client, correct? In other words, whether my class is 100 lines or 10,000 lines, it shouldn't have any affect on my bandwidth or transfer rate should it? Please correct me if I am wrong, but I have been operating under the assumption that the only thing that gets transferred to the client is the php file after it has been parsed for all html formatting, and the size of this final product is what affects the speed of transfer.
Thanks in advance.
Marcus <Ju********@aol .com> wrote: Quick question... I have a class that is over 1200 lines of code and 50 KB in size. This file does not display any html, it is just included and after I call all the necessary functions, I save the data and display it on my output page.
Here is my confusion - to the best of my understanding, since php is server side, this file should never be "transferre d" to the client, correct? In other words, whether my class is 100 lines or 10,000 lines, it shouldn't have any affect on my bandwidth or transfer rate should it? Please correct me if I am wrong, but I have been operating under the assumption that the only thing that gets transferred to the client is the php file after it has been parsed for all html formatting, and the size of this final product is what affects the speed of transfer.
True.
However, PHP does have to recompile that entire file for every page, unless
you are using a cache/optimizer. That takes time -- possibly a lot of
time.
--
- Tim Roberts, ti**@probo.com
Providenza & Boekelheide, Inc.
In article <jc************ *************** *****@4ax.com>,
Tim Roberts <ti**@probo.com > wrote: Marcus <Ju********@aol .com> wrote: Quick question... I have a class that is over 1200 lines of code and 50 KB in size. This file does not display any html, it is just included and after I call all the necessary functions, I save the data and display it on my output page.
Here is my confusion - to the best of my understanding, since php is server side, this file should never be "transferre d" to the client, correct? In other words, whether my class is 100 lines or 10,000 lines, it shouldn't have any affect on my bandwidth or transfer rate should it? Please correct me if I am wrong, but I have been operating under the assumption that the only thing that gets transferred to the client is the php file after it has been parsed for all html formatting, and the size of this final product is what affects the speed of transfer.
True.
However, PHP does have to recompile that entire file for every page, unless you are using a cache/optimizer. That takes time -- possibly a lot of time.
This is why I broke my code libraries into functional parts. That way,
each page can require what it needs and only what it needs.
--
DeeDee, don't press that button! DeeDee! NO! Dee... This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Dave Smithz |
last post by:
Hi There,
I have a PHP script that sends an email with attachment and works great when
provided the path to the file to send.
However this file needs to be on the same server as the script.
I want to develop a webpage where people can send attachments that are
stored on their local PC.
|
by: Joe |
last post by:
Hello,
I have IIS 6.0 running on w2k3 Enterprise.
I have three upload forms
1 to have restricted uploads .asp
2 to upload plain .asp any extension
3 a FP form upload non .asp
|
by: Sunner Sun |
last post by:
Hi!
I have looked through the FAQ but found nothing about it. :-)
It seems that this kind of macro is platform dependent, doesn't it?
Thank you.
Sunner Sun
|
by: Suyog_Linux |
last post by:
I wish to know how the free()function knows how much memory to be
freed as we only give pointer to allocated memory as an argument to
free(). Does system use an internal variable to store allocated memory
when we use malloc().
Plz help......
|
by: Sam |
last post by:
Hi all,
Is there a function in the standard library that can get the size of a file?
Thank you very much.
Sam.
| |
by: Cuthbert |
last post by:
After compiling the source code with gcc v.4.1.1, I got a warning
message:
"/tmp/ccixzSIL.o: In function 'main';ex.c: (.text+0x9a): warning: the
'gets' function is dangerous and should not be used."
Could anybody tell me why gets() function is dangerous??
Thank you very much.
Cuthbert
|
by: Adi |
last post by:
Hello eveyone,
I wanna ask a very simple question here (as it was quite disturbing
me for a long time.)
My problem is to read a file line by line. I've tried following
implementations but still facing problems:
Assume that
FILE* filePointer;
unsigned char lineBuffer;
|
by: rn5a |
last post by:
Consider the following code:
<script runat="server">
Sub Page_Load(ByVal obj As Object, ByVal ea As EventArgs)
Dim dInfo As DirectoryInfo
dInfo = New DirectoryInfo(Server.MapPath("/Folder1"))
dgFD.DataSource = dInfo.GetFiles("*.*")
dgFD.DataBind()
End Sub
|
by: Ashit Vora |
last post by:
Hi,
I 'm new to C programming and 'm stuck somewhere.
I want to find the size of a file.
I couldn't find a proper way of doing it.
What I was planning to do is...
Open the requested file,
default position is 1st byte.
Now I use fseek() and move it till the send of the file.
Than I use ftell() to get the current position in the file.
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
| |
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
| |
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |