473,396 Members | 1,892 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

dynamic content

i wrote a website for somebody, in php and mysql. The person i wrote it
for wanted it to be as simple to administer as possible, so i set up
phpmyadmin for the database, and showed him how to upload pictures using
ftp (productid.jpg). so i scaled these pictures down to small pictures
(bad practice i know, but he wants it simple), and onclick it shows the
pictures full size in a new window.

anyway, theres a problem with the speed. obviously once there are a few
items on the page, the pictures are going to really slow down the page, so
i was wondering if there is anyway to have a button by each item, then
onClick, replace the button with the relevant picture. it has to be
dynamic, and there's going to be different buttons with different pictures
on each item, so the code cant go in the <head>

the page is http://www.houseproudlancs.co.uk/search.php
Jul 20 '05 #1
1 1180
In article <pan.2004.02.07.13.24.17.195713
@microsoftscrappywebserver.com>, mattyrobinson69
@microsoftscrappywebserver.com enlightened us with...

anyway, theres a problem with the speed. obviously once there are a few
items on the page, the pictures are going to really slow down the page, so
i was wondering if there is anyway to have a button by each item, then
onClick, replace the button with the relevant picture.


Target browser(s)?
If you need to support all browsers, including NN4, then it's more of a
PITA.

If not, just have a div with a unique id for each pic, buttons, and an
onClick for each button that passes the src for the pic and the div id
to a function. The function creates an image (createElement) with that
src and appends it (appendchild) to the div. That technique will work in
all browsers that support those DOM methods, including IE5+, NN6+,
Mozilla, and Opera 6(5?)+.

However, this seems a bit much when you could just thumbnail the pics.
There's PHP thumbnail programs out there.

http://www.google.com/search?q=php+t...UTF-8&oe=UTF-8
&start=10&sa=N

http://groups.google.com/groups?hl=e...UTF-8&oe=UTF-8
&q=php+thumbnail&sa=N&tab=wg

--
--
~kaeli~
A man needs a mistress... just to break the monogamy.
http://www.ipwebdesign.net/wildAtHeart
http://www.ipwebdesign.net/kaelisSpace

Jul 20 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
by: K | last post by:
I have found a script online that I want to use (I am new to PHP). It creates dynamic images based on the text that you pass it. However, no matter how I try, I can't get anything other than a...
3
by: Stephen Gennard | last post by:
Hello, I having a problem dynamically invoking a static method that takes a reference to a SByte*. If I do it directly it works just fine. Anyone any ideas why? I have include a example...
3
by: Guy Harwood | last post by:
Hi, I have designed a textbox that inherits from the System.Windows.Forms.Textbox control. when the control is readonly the back color changes to a light blue to indicate that it is frozen. ...
3
by: NateDawg | last post by:
I'm reposting this. I'm kinda in a bind untill i get this figured out, so if anyone has some input it would sure help me out. Ok, I’ve noticed a few gridview problems floating around the forum....
7
by: Mike Livenspargar | last post by:
We have an application converted from v1.1 Framework to v2.0. The executable references a class library which in turn has a web reference. The web reference 'URL Behavior' is set to dynamic. We...
2
by: serge calderara | last post by:
Dear all, Technically, what dynamic web page really means. Is it simply due to the fact that the content can be change without recompiling the web application by simply changing for example data...
2
by: dawg1998 | last post by:
I have a page that creates dynamic textboxes based on the number of fields a user chooses to fill out. This process worked great when the page was standalone. However, when I move to a...
2
by: jitu78 | last post by:
Hi All, I am having problem with Pixel fonts in Flash. When I am using pixel fonts for dynamic contents, textual data is looking blurry. They are showing right with static content. That’s...
7
by: Jo | last post by:
Hi, How can i differentiate between static and dynamic allocated objects? For example: void SomeFunction1() { CObject *objectp = new CObject; CObject object;
9
by: pbd22 | last post by:
Hi. This is just a disaster management question. I am using XMLHTTP for the dynamic loading of content in a very crucial area of my web site. Same as an IFrame, but using XMLHTTP and a DIV. I...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
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,...
0
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...
0
tracyyun
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...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.