Both for that matter. I have root access. I want to echo how much /var/xxx contains,
and while I'm at it, how much my partition contains and how much is used.
Gerard Samuel wrote:
On Wednesday 18 February 2004 01:25 am, John Taylor-Johnston wrote:
I'm not even sure if this is a Unix thing
That was very helpful, thanks,
John
- Edwin - wrote:
Not that this is still a php question but...
On Wed, 18 Feb 2004 01:38:39 -0500
John Taylor-Johnston [EMAIL PROTECTED] wrote:
Both for that matter. I have root access. I want to echo how
much /var/xxx contains, and while I'm
thanks
Gerard Samuel wrote:
On Wednesday 18 February 2004 01:38 am, John Taylor-Johnston wrote:
Both for that matter. I have root access. I want to echo how much /var/xxx
contains, and while I'm at it, how much my partition contains and how much
is used.
Im not sure about memory
I want to create a language option, so the resulting html is in French or English,
depending. But passing variables like this doesn't work:
?php include (../_phpcode/byname.php?lang=fr); ?
echo $lang; // 'fr'
Warning: main(): Failed opening '../_phpcode/byname.php?lang=fr'
Why didn't I think of that :) ?
Thanks John,
John
John W. Holmes wrote:
From: John Taylor-Johnston [EMAIL PROTECTED]
I want to create a language option, so the resulting html is in French or
English, depending. But passing variables like this doesn't work:
?php include (../_phpcode
Basically I have an enum field. I would like to extract the parts of the field to
create some html.
district enum('part1','part2','part3','part4')
while (district??)
{
echo a href=\page.htm#.district[0].\.district[0]./a
}
a href=page.htm#part1part1/a
a href=page.htm#part2part2/a
a
backslashes for the double quotes. I'm also using commas to echo
the 5 parts in sequence, rather than concatenate them then echo the result.
-Original Message-
From: John Taylor-Johnston [mailto:[EMAIL PROTECTED]
Sent: Monday, February 23, 2004 7:58 PM
To: [EMAIL PROTECTED]
Cc
:57, John Taylor-Johnston wrote:
Basically I have an enum field. I would like to extract the parts of the
field to create some html.
Can I even do this?
yes
How?
archives
--
Jason Wong - Gremlins Associates - www.gremlins.biz
--
Search the list
I know I have something in here that did it. [Shake, shake, rattle, bump]
This is how I send an image in a postcard maker I fashioned once:
http://www.CollegeSherbrooke.qc.ca/languesmodernes/jtjohnston/0postcard0/send_mail.phps
Hmm.
http://marc.theaimsgroup.com/?l=php-generalm=106933918806372w=2
-Original Message-
From: Alan Lord [mailto:[EMAIL PROTECTED]
Lord?! Wasn't one of those perl dark lords was it? :)
I'll try the code.
Jason Wong wrote:
On Tuesday 24 February 2004 13:45, John Taylor-Johnston wrote
Anyone recommend a good calendar class at phpclasses.org or elsewhere?
Something I can install with ease and teach someone else to use and update using, oh
say phpmyadmin?
Thanks,
John
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Manuel,
Do you have a command line access to the server?
http://httpd.apache.org/docs/programs/htpasswd.html
htpasswd -b /var/www/html/db/tools/htpasswd.users jdaxell ** (batch mode)
htpasswd -c /var/www/html/db/tools/htpasswd.users jdaxell (creation mode)
htpasswd
I'm trying to figure out something. I found some calendar making code. For each table
cell, I want to add a href=$day/a around $day if an entry exists in $db.$table
$sql = 'SELECT * FROM '.$db.'.'.$table.' where eventid like '.$eventid.';';
if ($sql ??)
{echo tda href=\\$day/a/td;
}else{
echo
?eventid=$link_date $day /a/td;
}else{
echo td $day /td;
}
Bao Ruixian wrote:
John Taylor-Johnston wrote:
$sql = 'SELECT * FROM '.$db.'.'.$table.' where eventid like '.$eventid.';';
if ($sql ??)
This will do:
if ($sql)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit
eventid like '.$eventid.';';
#echo $sql;
#SELECT * FROM GMCalendar where eventid like 2004-02-16;
$glquery = mysql_query($sql);
if ($glquery)
{
echo tda href=results.php?eventid=$link_date $day /a/td;
}else{
echo td $day /td;
}
Bao Ruixian wrote:
--
John Taylor-Johnston
Richard,
Thanks. Should I still include the die ?
$myconnection = mysql_connect($server,$user,$pass);
mysql_select_db($db,$myconnection);
$eventid = $link_date;
$sql = 'SELECT * FROM '.$table.' where eventid like \''.$eventid.'\';';
$glquery = mysql_query($sql) or die(Invalid query: .
Very helpful much appreciated.
Richard Davey wrote:
Hello John,
Wednesday, February 25, 2004, 6:26:41 PM, you wrote:
JTJ Richard,
JTJ Thanks. Should I still include the die ?
JTJ $glquery = mysql_query($sql) or die(Invalid query: . mysql_error());
It's up to you, I never do. It won't
Is there a way to reverse engineer http://www.php.net/manual/en/function.date.php ?
I want to feed in 2003-02-28 and extract February 28, 2003. I can substr it out ...
$eventid = 2003-02-28;
$year = substr($eventid, 0,4);
$month = substr($eventid, 5,7);
$year = substr($eventid, 8,10);
But
Is there a function to strip html from a string?
This function seems to stip out everything between the tags too, no?
http://www.php.net/manual/en/function.strip-tags.php
John
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Scrap that. Sorry. My fault. Understood. :)
J
John Taylor-Johnston wrote:
Is there a function to strip html from a string?
This function seems to stip out everything between the tags too, no?
http://www.php.net/manual/en/function.strip-tags.php
John
--
PHP General Mailing List (http
Just wondering why some do and some don't use safe mode,
It comes set to off in php.ini. Paranoia likely, I don,t know.
You are talking about this in php.ini?
; Safe Mode
;
safe_mode=Off
You might be able to turn it off in your script? Run phpinfo(); to see if it is
available. Someoen with
Am I doing this right? Is there a better way? Am I doing this key thing right?
I'm doing the language thing. I have no extra plugins or rpms to help do this
properly. So I need advice. Is this going to work? I'm trying to make sense of
http://www.php.net/manual/en/language.types.array.php
$date
http://www.php.net/manual/en/function.setlocale.php
That is the problem. I have tried that, but it needs to be installed. I'm not in a
position to ask on this particular server. I have PHP Version 4.3.4 all the same.
http://www.glquebec.org/English/test.php
The code echoes
Friday 22 December
How might I email into my php script. I have created a little BBS and would like to
combine the functionality of an emailing list, a bit like Yahoo groups.
Every time there is a post on my BBS, subscribed users get a copy. But, they would
like to reply to the email, not click on a URL. When
How can I check if a table exists in a mysql db. If it table does not exist, then,
$news = mysql_query($sql_create);
else
$news = mysql_query($sql);
Not sure I know where to start?
-snip
$server = localhost;
$user = user1;
$pass = ;
$db=user1table;
$table=comments;
I used phpmyadmin to help generate some code. When I add:
IF NOT EXISTS `mhinse_counter` it mysql_errors that the error is around:
IF NOT EXISTS `mhinse_counter` CREATE TABLE `mhinse_counter` (
Can anyone see clear here?
$server = localhost;
$user = user1;
$pass = **;
But wouldn't it be easier to create the tables in the first place?
Travis,
It surely would. But for one situation, I don't/can't have access to phpMyAdmin to
install it.
At the same time, I wanted to learn how to do it.
--
John
I'm still learning. But isn't this much more fun than Perl!
To
,
Malaria Research Group,
ICGEB , New Delhi.
INDIA
Phone: 91-9811261804
91-11-26173184; 91-11-26189360 #extn 314
--
John Taylor-Johnston
-
If it's not open-source, it's Murphy's Law.
' ' ' Collège de Sherbrooke
, New Delhi.
INDIA
Phone: 91-9811261804
91-11-26173184; 91-11-26189360 #extn 314
--
John Taylor-Johnston
-
If it's not open-source, it's Murphy's Law.
' ' ' Collège de Sherbrooke:
ô¿ô http
Should have read:
CREATE TABLE IF NOT EXISTS `mhinse_counter`
mysql_error said:
IF NOT EXISTS `mhinse_counter` CREATE TABLE `mhinse_counter` (
Thanks to all.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Costs money too!?
Steve Magruder - Webcommons.Org wrote:
phpBB (www.phpbb.com) is the best (IMHO), as it has an extensive modder
community and it's slap-easy to install and get running.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
I personally prefer:
http://www.chevelles.com/cgi-bin/forum/ultimatebb.cgi?ubb=forum;f=39;hardset=;start_point=;DaysPrune=
http://www.ubbcentral.com/ubbclassic/
But it does cost $ I believe. However, this particular site has a mutilated forum.
Part of it was originally Perl. Their switch over
input type=\checkbox\ Name=protid1 value=\$variable\
input type=\checkbox\ Name=protid2 value=\$variable\
input type=\checkbox\ Name=protid3 value=\$variable\
input type=\checkbox\ Name=protid4 value=\$variable\
Or give all name=protid[] and you will get array $_POST['protid'] that
Anyone know what aspx is? A rogue version of asp? It's not Open Source or PHP in
disguise?
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Sorry, MySQL question. Any takers? If I search for 'margaret atwood', I get results in
no real structured heirachy. Any thoughts?
SELECT ST,BT,AT FROM ccl_main WHERE MATCH (ST,BT,AT) AGAINST ('margaret atwood' IN
BOOLEAN MODE);h1Search font color=blueccl.ccl_main/font For: font
I would have at least expected it give me 'margaret atwood' before it gives me
'margaret' and then 'atwood'.
Sorry, MySQL question. Any takers? If I search for 'margaret atwood', I get results
in no real structured heirachy. Any thoughts?
SELECT ST,BT,AT FROM ccl_main WHERE MATCH
nl2br I think is what you wnat.
http://www.php.net/manual/en/function.nl2br.php
Brent Clements wrote:
Ok I have a general problem.
I have a textarea on an html form.
Well when the user get's to the end of the textarea, it wrap's around. The problem
with this is that unless they do a
How can I calculate how many records I have in a table?
John
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
I might add, I do this, think there must be a better way?
$mycounter = 0;
while ($mydata = mysql_fetch_object($news))
{
$mycounter++;
}
John Taylor-Johnston wrote:
How can I calculate how many records I have in a table?
John
--
PHP General Mailing List (http://www.php.net
I have a longblob with a jpeg loaded in it. But how do I display it?
`photo` longblob NOT NULL,
This doesn't work :) I need header information, etc. So what does?
echo img src=.$mydata2-photo.\n;
I don't have an example to work with.
John
--snip-
$sql2 = select * from
pages and the Internet.
Any objections? There was an article someplace about Rasmus Lerdorf calling it
such, in the beginning. (http://www.php.net/manual/en/history.php)
(recursive acronym for PHP: Hypertext Preprocessor)
»» This is the general group. It is a general question? :)
--
John Taylor
?
?php
#old code:
$week1 = 2005-01-17;
$week2 = 2005-01-24;
...
$week17 = 2005-05-09;
if(date(Y-m-d) = $week3)
{
echo this is week 3);
}
?
Thanks,
John
--
John Taylor-Johnston
-
If it's not Open Source, it's Murphy's
= 2005-02-07;
$week5 = 2005-02-14;
$week6 = 2005-02-21;
$week7 = 2005-02-28;
`Doable´? Easy enough to learn how to do?
John
--
John Taylor-Johnston
-
°v° Université de Sherbrooke
/(_)\ http://compcanlit.ca
);
// add 4 days
$lastDayTs = $firstDayTs + (4 * 86400);
echo date('F', $firstDayTs) . ' ' . date('m', $firstDayTs) . '-' . date('m',
$lastDayTs);
Not tested. Maybe there's an easier way to do this.
Regards, Torsten Roehr
--
John Taylor-Johnston
) . '-' .
date('Y',$firstDayTs) .br;
echo date('F', $firstDayTs) . ' ' . date('m', $firstDayTs) . '-' .
date('Y',$lastDayTs) .br;
?
John
Roehr wrote:
John Taylor-Johnston [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
I might be doing this backwards, but how do I extract the date
David http://dev.mysql.com/doc/mysql/en/Fulltext_Boolean.html
David Quote:
David They do not automatically sort rows in order of decreasing relevance.
David You can see this from the preceding query result: The row with the highest
relevance is
David the one that contains ``MySQL'' twice, but it
Hi,
I need another variable. I need the filename itself. I want to substitute
/var/www/html/new1/foo.html
for
/var/www/html/new1/phpinfo.htm
and then include
/var/www/html/new1/html/phpinfo.htm
This doesn't do it anymore. I can't see a way to go up to directory html:
?php
Apache can do this too, right?
I'm sure I saw a bit of code floating about?
Torsten Roehr wrote:
Shaun [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
Hi,
Please could someone tell me how I can redirect a user to the page they
came
from including any query strings attached
I have a menu with a bunch of items. How can I clean up this code and push it through
a function?
Your basic newbie Question :)
Thanks,
John
pa class=nav href=index.html?php
if(stristr($_SERVER[SCRIPT_FILENAME],index.html))
{
echo bHome/b;
}else{
echo Home;
}
?/a
pa class=nav href=index.html?php
I have created an .inc that allows me to click on a submit to show the next or
previous 25 records found etc. The problem is that if $searchenquiry includes a
quotation mark, the html looks like:
input type=hidden name=searchenquiry value=atwood's -margaret\
Is there a function to encode
an hour since i subscribed and i still haven't
received any messages so i'm sending this one as a test.
--
John Taylor-Johnston
-
Université de Sherbrooke:
http://compcanlit.ca/
--
PHP General Mailing List (http
--
John Taylor-Johnston
-
If it's not open-source, it's Murphy's Law.
' ' ' Collège de Sherbrooke:
ô¿ô http://www.collegesherbrooke.qc.ca/languesmodernes/
- Université de Sherbrooke:
http
Torsten
Here it is, if it is any use to you?
John
---
$sql = 'SELECT *,MATCH (KW,AUS)
AGAINST (\''.stripslashes($searchenquiry).'\' IN BOOLEAN MODE)
AS relevancy FROM '.$table.'
WHERE MATCH (KW,AUS)
AGAINST
I'm using this, but it is wrong.
$mydata-JR = eregi_replace($searchenquiry, b.$searchenquiry./b, $mydata-JR);
echo $searchenquiry;
What I should display is if $searchenquiry = $mydata-JR in a case insensitive way then
echo b.$searchenquiry./b;
Do I use if (x =~ b) {} or some sort of string
if (strtoupper($searchenquiry) == strtoupper($mydata-JR) )
The problem is $searchenquiry would be contained inside $mydata-JR so I would need to
see if it exists and then put b.../b around it, without changing the original case.
Thanks,
J
Matt M. wrote:
$mydata-JR =
$searchenquiry = Never cry Wolfe
and
$mydata-ST contains ... Never Cry Wolfe ...
This code echos:
td.preg_replace ('/('.$searchenquiry.')/i' , b$1/b, $mydata-ST).nbsp;/td
td... bNever cry Wolfe/b .../td
But I want it to use the original text and echo:
td... bNever Cry Wolfe/b .../td
Do-able?
isnt that what you want?
Hmm? Yes. But it doesn't work for me? It cannot be a php verison thing, can it?
I have phpversion() 4.1.2. I don't get it? :)
Compare with:
http://compcanlit.usherbrooke.ca/new1/db/index.php?searchenquiry=Never%20Cry%20Wolfe
and then:
isnt that what you want?
I don't see anything in the manual that says it can't?
http://ca3.php.net/manual/en/function.preg-replace.php
Thanks for trying.
John
$searchenquiry = Never cry Wolfe
and
$mydata-ST contains ... Never Cry Wolfe ...
This code echos:
td.preg_replace
('/('.$searchenquiry.')/i' , b$1/b, $mydata);
echo td$newnbsp;/td;
here was my output:
td... bNever Cry Wolfe/b ...nbsp;/td
isnt that what you want?
--
John Taylor-Johnston
-
If it's not open-source, it's Murphy's Law
Keyword AND keyword2
keyword keyword2 -keyword3
It doesn't support AND or OR but it does use - + * and others.
Consult thine manual!! (The MySQL one) ;)
http://dev.mysql.com/doc/mysql/en/Fulltext_Search.html
The problem is getting a FULLTEXT to sort by relevancy. This was a real pain, until
).searchenquiry=.urlencode($author).\.$ausid./a,
;
}
$temp = substr($temp, 0, -2);
echo $temp/td;
echo tdnbsp;/td;
echo /tr\n;
}
}
--
John Taylor-Johnston
-
If it's not open-source, it's Murphy's Law.
' ' ' Collège
...?
--
-
Michael Mason
Arras People
www.arraspeople.co.uk
-
--
John Taylor-Johnston
-
If it's not open-source, it's Murphy's Law.
' ' ' Collège de Sherbrooke
I'm having another problem with sort();
I want to treat $rbenquiry as a string, not as a numeral.
$mydata-RB could contain 1.2 ; 1.9 ; 1.1 ; 1.0 ; 1.0.8
But if $rbenquiry =1.0, my code spits out anything that begins as though it were
=1. It should only display 1.1 or 1.0.8.
Where did I go
I'm having a similar problem here if I pass a numeral inside $searchenquiry
$searchenquiry = 1.0.1 Retrospective bibliographies and checklists / bibliographies
et répertoires rétrospectifs;
preg_replace ('/('.$searchenquiry.')/i' , b$1/b, $mydata-RB)
error: Unknown modifier 'b' in
Ok. This is not a numeral problem? strval did not make a difference.
I have, however, solved the immediate problem with:
# if((strtolower(substr($enquiry, 0, 1)) == $rbenquiry))
if((strtolower(substr($enquiry, 0, strlen($rbenquiry))) == $rbenquiry))
However, preg_replace
I went with this, but am getting a parse error.
usort($authors, create_function('$a,$b','
$a = str_replace(array('é', 'à'), array('e', 'a'), $a);
$b = str_replace(array('é', 'à'), array('e', 'a'), $b);
return strcasecmp($a,$b);'));
Anyone see it? I've got headaches from
Like this?
td.preg_replace ('/('.preg_quote($searchenquiry).')/i' , b$1/b,
$mydata-JR).nbsp;/td
Still getting the unknown modifier error.
$searchenquiry = 1.0.1 Retrospective bibliographies and checklists /
bibliographies et répertoires rétrospectifs;
preg_replace
You don't need sendmail. In php.ini you need to add something.
SMTP = [EMAIL PROTECTED] is not right? You want an address, not an email.
SMTP = smtp.uol.com.br is more likely the correct address.
Joao Gomes wrote:
Hi,
I am a beginner in php and I am trying to send emails from my machinne,
on this page I get:
Code:
?php echo for example: ['$UserID']; ?
Generates:
for example: ['\JDoe\']
Which part of my syntax is incorrect...?
--
-
Michael Mason
Arras People
www.arraspeople.co.uk
-
--
John Taylor-Johnston
In my c«ase, it was built into redhat. Installing it in a local user account? Can't do
that, but I'm no expert. You would need root-lvel access to change variables on the
server too, no? In php.ini for one. Ask your sysadmin for an account.
Levis li wrote:
Hi friends
I am now using the
Finally something I can give back, made by my little lonesome with no help :)
I have a query that returns lots of rows so I want to display the results in blocks
of 25 or so on my web page and have forward and back buttons to navigate the results.
include it first:
Sorry. Still getting a parse error on line 40:
39 usort($authors, create_function('$a,$b','
40 $a = str_replace(array('é', 'à'), array('e', 'a'), $a);
41 $b = str_replace(array('é', 'à'), array('e', 'a'), $b);
42 return strcasecmp($a,$b);'));
Can you have two arrays
http://compcanlit.usherbrooke.ca/new1/db/index.php?ausenquiry=e
http://compcanlit.usherbrooke.ca/new1/db/index.php?ausenquiry=é
It still sorts é and e separately, but without a parse error:
$first = array('à', 'é');
$second = array('a', 'e');
usort($authors, create_function('$a,$b','
');
var_dump($authors);
?
regards,
m.
John Taylor-Johnston wrote:
http://compcanlit.usherbrooke.ca/new1/db/index.php?ausenquiry=e
http://compcanlit.usherbrooke.ca/new1/db/index.php?ausenquiry=é
It still sorts é and e separately, but without a parse error:
$first = array('à', 'é');
$second
Sorry, doesn't work either.
http://compcanlit.usherbrooke.ca/new1/db/index.php?ausenquiry=e
does not contain those that start with é:
http://compcanlit.usherbrooke.ca/new1/db/index.php?ausenquiry=é
function usort_callback($a, $b) {
$a = str_replace(array('à', 'é'), array('a', 'e'),
Hi,
I'm trying to sort my array. My Usort works, but this line only chooses those that
begin with an e:
if((strtolower(substr($author, 0, 1)) == $ausenquiry))
http://compcanlit.usherbrooke.ca/new1/db/index.php?ausenquiry=e
is different from:
I'm reading data. Can I open a connection within a connection and write data to
another $db.$table or do I have to write my data to an array. In an array, how do I do
this?
I've looked at array_push, but don't think this is what I want?
$authors = array();
Can someone help me, show me how to do this please?
1. How do I write $mydata-AUS and $mydata-id into an array?
$authors = array();
while ($mydata = mysql_fetch_object($news))
{
# echo $mydata-AUS, $mydata-id\n;
??? write to array
}
mysql_close($myconnection);
2. Then I need to create $SQL
complicated than that, but advice on coding this much would help.
John
P.S. my condoleances to New York today. Can't believe it was 3 years ago already.
John Holmes wrote:
John Taylor-Johnston wrote:
1. How do I write $mydata-AUS and $mydata-id into an array?
$authors = array();
while
Thanks. As a newbie, something I like to try also is making a second file with phps as
the extension.
Sometimes reading my code in colour helps me see things better. Sometimes I forget a
semi-colon ; and will see the problem immediately.
Ma Sivakumar wrote:
John,
$sql .= INSERT INTO newtable VALUES ({$mydata-AUS},{$mydata-id});\r\n;
I thought mysql would not permit that, running more than one query (insert ...) at a
time?
You can get away with it in phpmyadmin, although.
--
John Taylor-Johnston
MySQL question:
DROP TABLE IF EXISTS
Instead of dropping the table, I want to truncate the table if it contains something.
ANyone know of a way? I couldn't find anything under truncate in the manual.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit:
=\left\;
$temp = ;
foreach ($author_list[$author] as $ausid)
{
$temp .= $ausid, ;
}
$temp = substr($temp, 0, -2);#delete ,
echo $temp/td;
echo /tr\n;
}
--
John Taylor-Johnston
=\left\;
$temp = ;
foreach ($author_list[$author] as $ausid)
{
$temp .= $ausid, ;
}
$temp = substr($temp, 0, -2);#delete ,
echo $temp/td;
echo /tr\n;
}
--
John Taylor-Johnston
Jason, I agree. Sorry. I sent it as a new message. I will try again,
John
Jason Wong wrote:
You have started a new thread by taking an existing posting and replying to
it while you changed the subject.
That is bad, because it breaks threading. Whenever you reply to a message,
your mail
, unexpected T_IS_EQUAL in c:\TSW\pages\testing2.php
on line 3
So it isn't working. How do I get to let me make comparisons between the post
data and something else? I figure if I can get it so that this will work,
it'll be an easy way to password protect my pages...
-Andrew
--
John Taylor
=\#F5F5F5\tdnbsp;/td;
echo td align=\left\;
$temp = ;
foreach ($author_list[$author] as $ausid)
{
$temp .= $ausid, ;
}
$temp = substr($temp, 0, -2);#delete ,
echo $temp/td;
echo /tr\n;
}
--
John Taylor-Johnston
=\#F5F5F5\tdnbsp;/td;
echo td align=\left\;
$temp = ;
foreach ($author_list[$author] as $ausid)
{
$temp .= $ausid, ;
}
$temp = substr($temp, 0, -2);#delete ,
echo $temp/td;
echo /tr\n;
}
--
John Taylor-Johnston
Parse error: syntax error, unexpected T_BOOLEAN_AND in c:\TSW\pages\testing2.php on
line 3
My code should do what you want? It uses authenticate? Any how :) I think you are
missing acouple of brackets?
if (
($_POST['user'] == 'Andrew') ($_POST['pass'] == 'pass')
)
{
echo Welcome, Andrew.;
}
I want to open table 2 inside table1. See $sql2 below. I know this is illegal.
How can I work around this? Or can I? Lost cause?
John
$myconnection = mysql_connect($server,$user,$pass);
#mysql_select_db($db,$myconnection); #not necessary
$sql1 = 'select * from '.$db.'.'.$table.' order by
addslashes($MY_HTML) might help?
http://ca3.php.net/manual/en/function.addslashes.php
John
Jay Blanchard wrote:
[snip]
Hi!
i have:
$html = '
html
MY HTML
/html
';
Inside of my html i used ', this produced a parse error, how can i
solved
it?.
addslashes()
Juan Pablo Herrera wrote:
Escape it: \'
It must be somewhere in the manual, I think.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Maybe I should insert the contents of table2 into an array. Then in my while() I echo
$participant[$mydata1-district] and $biography[$mydata1-district]
If this is the best solution, how do I code it?
John Taylor-Johnston wrote:
I want to open table 2 inside table1. See $sql2 below. I know
Curt,
Thanks.
#mysql_select_db($db2,$myconnection2); #not necessary
Why isn't this necessary? if you have just opened a connection you
must select a database. Besides the fact that the second connection
isn't necessary.
From what I have experimented with, if I declare $db.$table in my
I know there is a way to print to pdf. Wh«t about rtf?
I'm getting real tired of doing it myself. Must be an easier answer?
header(Content-type: text/rtf);
header(Content-Disposition: attachment; filename=directory.rtf);
echo
Hi,
My question: can I open $table2 within $table1 - I thought so.
I thought I had this set up correctly. Sorry to throw all these lines of code at you.
But I need to situate the error for someone to see plainly what I'm doing.
I'm getting this error:
Warning: mysql_fetch_object(): supplied
Ramil,
Got that. thanks. Yeah, I mis-named a field in the seond table. Needed to name title
for district
$sql2 = select * from .$db...$table_GLOfficers. where title=' .
$mydata-district. ';
Thanks for that. Getting late, i guess.
John
--
PHP General Mailing List (http://www.php.net/)
To
Consistently crashes my Netscape 4.8 (circa 2003). yeah, I still use it, because I
prefer its news reader. Very few attacks on this mature mail program. That said,
you're forcing me to use IE6 :-|
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit:
How do I take 2007-02-01 and turn it into Thursday, February 1, 2006?
Simple question, except I don't know the answer :)
This is all I see for now:
http://ca.php.net/manual/en/function.px-date2string.php
John
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit:
Chris wrote:
John Taylor-Johnston wrote:
How do I take 2007-02-01 and turn it into Thursday, February 1, 2006?
Use strtotime (http://php.net/strtotime) to turn it into a timestamp and
then format it using date (http://php.net/date).
echo date(l, F j, Y, strtotime(2007-02-01));
That's
401 - 500 of 562 matches
Mail list logo