No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.
20 Posted Topics
I am persevering with Javascript slowly, and attempting to modify a code I saw that I thought would work for me - click to change/enlarge image and attach appropriate caption. I have: function showPreview(path){ var theImageElement=document.getElementById("img"); var theCaptionElement=document.getElementById("legend"); theImageElement.src = path; /*if(path == "../WSRUxhtml/photo/LImg/Barfleur.jpg"){ theCaptionElement.innerHTML="Barfleur arriving at Portsmouth"; } else … | |
I have read about browser compatibility and made amendments so that a slideshow works on my website as intended on 4 browsers. I have checked it on my laptop with Mozilla-Firefox, Google-Chrome,Safari, Opera and IE8 using Windows 7 Home Premium and still have an issue with IE8. However from my … | |
I have a series of images which are enlarged in a popup.div over a blanket.div.I have also added a back/forward button to the popup.div to move from one enlarged image to the next/previous. The buttons and images do what I want but the blanket.div only appear with the first image … | |
When the page opens all 12 popupDiv (large) images are centered in a stack. Why ? Having closed them all, the page then behaves the way I want i.e. onclick the popupDiv appears and one can go to the next or preceding large image. Can someone explain what is making … ![]() | |
I think this is a javascript query rather than css. The script opens and resizes images centering div on the screen. I have inserted function opendiv(id) so that one can go forward and back through the images on the webpage. This part works except that the images no longer center … ![]() | |
Have I got this totally wrong ? It should be simple. Whatever I try I return the COMPLETE A-Z and never the selected letter only. It seems I am not able to change the variable $name at all. The relevant code I have made is: <?php $alphasearch=''; $spanSearch = range('A','Z'); … | |
I have some experience of PHP but limited knowledge of handling arrays. My db table has 5000+ rows and 13000 populated fields. I want to create an alphabtical, visible index of the contents of each field, possibly for inclusion in an html page. If this possible, can it be initiated … ![]() | |
I can display an alpha index of the table contents using a form as follows: <?php if (isset($_POST['name'])) $name = ($_POST['name']); else $name = "no name entered"; ?> <form method="post" name="search" action="directory.php"/> <font family = "arial,verdana,sans-serif" color="#3F7cef"size="4"/>Select Letter</font> <input type="text" name="name" size="5" maxlength ="1" value="<?php if(isset($_POST['name'])){echo htmlentities($_POST['name']);}?>" /> <input type="submit" … | |
I have added 3 radio buttons to a form (no errors prior to this) for option to sort fetch_array result by field. I assume this is best done from the array but am making no progress - the results of $name,print_r($array) and tables are correct but no sorting. This Notice … ![]() | |
I need one result from 3 tables. The JOIN query fields of the first table repeat throughout the 3 tables. Is the JOIN query set out incorrectly or do I have to re-define the $row index in some way to avoid repetition of the fields. I have been using 3 … | |
I am trying to retrieve Mysql data, populate a form, user amend/delete fields, UPDATE and return data to database. It is the last stage that does not happen. I press UPDATE RECORD and screen returns to ID input. Where have I gone wrong, please ? <?php // require_once 'dbconnect.php'; if … | |
I want to insert values into 3 different tables with auto_increment of primary key. My code below creates 2 records for the first table and 1 each for the second and third AND a Failure 'duplicate entry xxxx for key PRIMARY' for the second and third. The ADD RECORD does … ![]() | |
I want to show users the number of records on the database. I have this on my html page: How many ships are listed ? <form action="rowcount.php" method="post" target="_blank"><input type="submit" value="Answer here" /> </form> with about 8,000 names. and this :[CODE] <?php require_once 'dbconnect.php'; $query="SELECT COUNT(name1) FROM allnames"; $result = … ![]() | |
I am trying to combine a MySQL query with change date format so all rows display as d-m-Y (surely possible ?) in results. The datefield type is DATE. [CODE]$query="SELECT * FROM table DATE_FORMAT('datefield','%d-%m-%Y')AS datefield FROM table";[/CODE] SELECT*FROM table on its own displays datefield as YYYY-MM-DD but DATE_FORMAT does not change … | |
I am trying to send results to a new page.The results are fine. i.e. once the form is submitted and all input validated I want the result to appear on the results.html page. I have been able to display the results.html but no data displayed. I attach some relevant code: … | |
On a MySQL table the Date column is set at YYYY-MM-DD with some dates shown as 0000-00-00 (Default set at NULL) where no date is available. This is OK until I display the web page that contains the php code for the SELECT query. All the 0000-00-00 dates are displayed … | |
i posted on this earlier and with forum help get my function code to work as I want when I test it. But when I insert it into the php document I only get errors. The function is: [CODE] <?php function fix_it($name) { $name=ucwords(strtolower($name)); echo $name; } ?>[/CODE] The document … | |
I have been able to write functions but cannot get them to work. Many sites show you how to write them but not how to call them in your web programming. Can someone explain why this call does not work for me ? the function is: [CODE] <? php function … | |
I have a simple form which echoes data from db. when name typed. It works fine when name is typed and submit pressed. But I see that even when no name is selected or, when existing results on screen, pressing submit brings up ALL names from table not just row … | |
Hi, I have been learning PHP/Mysql for only a few moths and am working on my own dynamic web-site. Stuck on what is probably very simple. User inputs name($name)in form. Table containing it has 15 fields - $name could be in any or none How do I put $name into … |
The End.