Search Results

Showing results 1 to 40 of 54
Search took 0.01 seconds.
Search: Posts Made By: whitestream6 ; Forum: PHP and child forums
Forum: PHP 4 Hours Ago
Replies: 2
Views: 138
Posted By whitestream6
I have tried php pagination, it only partially worked, giving me this message:
Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in...
Forum: PHP 1 Day Ago
Replies: 2
Views: 138
Posted By whitestream6
This is my code:

<?php
//connect to mysql
//change user and password to your mySQL name and password
mysql_connect("localhost","root","PASSWORDREMOVED");

//select which database you want...
Forum: PHP 2 Days Ago
Replies: 3
Views: 222
Posted By whitestream6
How would I use this in conjunction with my database records?
Also:


Also, how in SQL, automatically deleting the record after a certain time (e.g. in this case, the programme is an hour long,...
Forum: PHP 3 Days Ago
Replies: 4
Views: 171
Posted By whitestream6
This is an included file on one of my PHP sites on localhost:

<?
//connect to mysql
//change user and password to your mySQL name and password...
Forum: PHP 3 Days Ago
Replies: 3
Views: 222
Posted By whitestream6
I have tried again to solve this, but no luck so far...
Forum: PHP 3 Days Ago
Replies: 4
Views: 227
Posted By whitestream6
I got another error, the error being this:
.
Here's my code:
<?php
//connect to mysql
//change user and password to your mySQL name and password...
Forum: PHP 4 Days Ago
Replies: 4
Views: 227
Posted By whitestream6
I get these errors in a script of mine:
Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in C:\www\vhosts\myradiostation\test.php on line 13

and my original...
Forum: PHP 4 Days Ago
Replies: 3
Views: 222
Posted By whitestream6
This is the code for my TV guide website (stored on localhost)'s articles in PHP:

<?php
//connect to mysql
//change user and password to your mySQL name and password...
Forum: PHP 6 Days Ago
Replies: 6
Views: 232
Posted By whitestream6
I'm now getting this error:


I tried your code and got the above error...
Forum: PHP 6 Days Ago
Replies: 6
Views: 232
Posted By whitestream6
I've been trying to create a database-driven site, am new to this, have looked it up on Google and tried for myself, but need a bit of help.


<?php
// Connects to your Database...
Forum: PHP 22 Days Ago
Replies: 8
Views: 363
Posted By whitestream6
I was trying to set a HTML table with content already in place as an array - but if that's not possible, then not to worry, I will see what other HTML in arrays I can learn.
Forum: PHP 23 Days Ago
Replies: 8
Views: 363
Posted By whitestream6
How do you get this to work? - well, for more than simple <strong> and <i> tags - I'm trying to get a HTML table in as an array, if this is possible!

Any advice is appreciated!
Forum: PHP 29 Days Ago
Replies: 1
Views: 312
Posted By whitestream6
I've just been learning arrays, and so far it's going well :)
This is my current PHP code:
<?php
$states = array ('MD' => 'Maryland', 'IL' => 'Illinois', 'MI' => 'Michigan');
...
Forum: PHP Nov 9th, 2009
Replies: 11
Views: 379
Posted By whitestream6
Thank you for that advice - useful for if my site does have MySQL capacity, but my current webhost only offers PHP 5.28, with no databases available on the free hosting plan, so I've had to resort to...
Forum: PHP Nov 9th, 2009
Replies: 11
Views: 379
Posted By whitestream6
It is an episode guide for TV programmes, with the data stored in php variables.
Forum: PHP Nov 9th, 2009
Replies: 11
Views: 379
Posted By whitestream6
This is the variable for the episode titles:
$phptitle = "<NAME OF PROGRAMME>";

However, I have to manually change it for every page and add it as:

<?php
$phptitle = "test";
?>
Forum: PHP Nov 9th, 2009
Replies: 11
Views: 379
Posted By whitestream6
Do arrays have to be numbered automatically, or can they be like array[pagetitlename.php]?
Forum: PHP Nov 3rd, 2009
Replies: 7
Views: 315
Posted By whitestream6
I tried atli's suggestion, and it partly worked.
As for the URLs not being able to be found, they're only accessible locally, mapped via virtualhosts in Apache and a HOSTS file - otherwise...
Forum: PHP Nov 3rd, 2009
Replies: 7
Views: 315
Posted By whitestream6
Your code almost worked... except it displayed the same page repeatedly, despite the contents of 1, 2, 3, 4, 5, 6 and 7.php all being different.

How would I fix this? This code is for my localhost...
Forum: PHP Nov 2nd, 2009
Replies: 7
Views: 315
Posted By whitestream6
Basically what I'm trying to do... get the script to display a different page every day of the week.
Forum: PHP Nov 2nd, 2009
Replies: 7
Views: 315
Posted By whitestream6
This is my code which is intended to produce an URL like the following:
www.mysite.com/test.php?day=1


<?
if (!$_GET['day']) {
$day = date('N');
}
elseif ($_GET['day']==1){ ?>
<?php...
Forum: PHP Oct 31st, 2009
Replies: 11
Views: 676
Posted By whitestream6
$vwpassat = "<strong>\"<a href='$url1/buyers-guide/2010/volkswagen/passat.php'>VW PASSAT ARGENTINA</a>\"</strong>";

This seems to work - is this the correct syntax for bold quotation marks now?
Forum: PHP Oct 31st, 2009
Replies: 11
Views: 676
Posted By whitestream6
Thanks, that worked, however, how do I make the quotation marks bold within $autoguide1 - I only get the first one and it ends up as this:


- the second quotation marks set doesn't appear, for...
Forum: PHP Oct 31st, 2009
Replies: 11
Views: 676
Posted By whitestream6
Thank you for that - the code below worked:


However, what should I do to make the quotation marks bold within $autoguide1 without getting this error:
Forum: PHP Oct 31st, 2009
Replies: 11
Views: 676
Posted By whitestream6
This is the echo code from my site:

<?php
$url1 = "http://www.canadiandriver.com";
$url2 = "http://www.chevrolet.com.br";
$autoguide = "Autoweekly";
$autoguide1 = /"<b>"<a...
Forum: PHP Oct 29th, 2009
Replies: 11
Views: 379
Posted By whitestream6
I'm trying to set dynamic titles on my pages with a switch statement, but can't get it to work.

Tried ifelse using code gleaned from Google but it didn't work.

I'm trying to get it so that all...
Forum: PHP Oct 29th, 2009
Replies: 5
Views: 291
Posted By whitestream6
Now I'm getting this error message:


My code now:

<html>
<body>
<html>
<body>
<?
Forum: PHP Oct 29th, 2009
Replies: 5
Views: 291
Posted By whitestream6
I get this error now in my code:
Parse error: syntax error, unexpected '}', expecting T_ENDSWITCH or T_CASE or T_DEFAULT in C:\www\vhosts\mywebsite1\dayweek.php on line 25

<html>
<body>
<?
$i...
Forum: PHP Oct 29th, 2009
Replies: 5
Views: 291
Posted By whitestream6
This is my script, which is intended to show a different page depending on day of the week.

<html>
<? error_reporting(E_ALL);?>
<body>
<?
$i=$_GET['day'];

switch ($i) {
case 0:
Forum: PHP Oct 27th, 2009
Replies: 4
Views: 248
Posted By whitestream6
This is my code - which displays different articles and produces articles as http://www.mysite.com/testpage.php?test=1

<html>
<body>
<?
$i=$_GET['day'];
switch ($i) {
case 1:
...
Forum: PHP Aug 24th, 2009
Replies: 1
Views: 239
Posted By whitestream6
I've been trying out arrays recently, and this is my coding:
<?php
$data = array('autoguide1'=>'car',
'baz'=>'boom',
'scotland'=>'haggis',
...
Forum: PHP Aug 22nd, 2009
Replies: 0
Views: 194
Posted By whitestream6
I got arrays working first time! :)
This is the website's source code, the file is testing.php.
Source code:
<?php
$data = array('test'=>'testingpage',
'test1'=>'test1a',
...
Forum: PHP Aug 7th, 2009
Replies: 1
Views: 396
Posted By whitestream6
I'm trying to get multiple variables to work in the query string with PHP.

This is my code:
<?
$programme=$_GET['programme'];
switch ($programme) {
case 12578:
...
Forum: PHP Aug 1st, 2009
Replies: 6
Views: 638
Posted By whitestream6
What would I have to do to my query string?:

<?
$i=$_GET['carname'];
switch ($i) {
case 1:
include("1.php");
break;
case 2:
include("2.php");
Forum: PHP Jul 24th, 2009
Replies: 6
Views: 638
Posted By whitestream6
I'm still trying to figure this out... anyone got any advice?
Forum: PHP Jul 24th, 2009
Replies: 6
Views: 638
Posted By whitestream6
Thanks for that. Do I have to create a separate .htaccess or php file to get this to work?

I have http://www.mychevycars.com (virtual host)
and I want to split the pages (page1.php, page2.php)...
Forum: PHP Jul 24th, 2009
Replies: 6
Views: 638
Posted By whitestream6
Thank you for the tutorial last time on query strings :)
It worked for me, this is my working query string:
<?
$i=$_GET['vehicle'];
switch ($i) {
case Chrysler:
include("chryslernew.php");...
Forum: PHP Apr 11th, 2009
Replies: 10
Views: 1,278
Posted By whitestream6
Thanks, rm_daniweb, that worked very well!
One question - how do I get it to automatically show the right page on the right day, e.g. it show's day 1's page on Monday etc. without people having to...
Forum: PHP Apr 10th, 2009
Replies: 10
Views: 1,278
Posted By whitestream6
Thanks for that. How would I use it with my code:
<html>
<body>

<? if($_GET['day']==1){ ?>
<?php include("day1.php") ?>
<? }else if($_GET['day']==2){ ?>
<?php include("day2.php") ?>
<?...
Forum: PHP Apr 10th, 2009
Replies: 1
Views: 396
Posted By whitestream6
I have a PHP page with query strings in, and that works, but getting it to display the correct page depending on the day via a switch statement is a problem.

This is the code:
<html>
<body>
...
Showing results 1 to 40 of 54

 


About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC