Re: [PHP] Off the wall - sub-domain question

2013-08-22 Thread Dan McCullough
So its indexing http://www.domain.com/subdomain/page.php and you would
rather it index http://subdomain.domain.com/page.php.  If that is the case
then what Willie said holds true

User-agent: *
Disallow: /subdomain

Place a robots.txt in the domain.com public root directory.

To Googles indexer http://subdomain.domain.com/page.php and
http://www.domain.com/subdomain/page.php are totally different and
therefore blocking /subdomain will not affect subdomain.domain.com.

Sign up for Google Webmaster and add two sites subdomain.domain and
www.domain  that way you can delete improperly indexed pages.
Do some test scans and see if there are links on your www.domain that are
linked to www.domain.com/subdomain rather then subdomain.domain.com


On Thu, Aug 22, 2013 at 9:43 AM, Willie  wrote:

> The only way that I know of to take care of that is to put a file in your
> main directory called "robots.txt". In that file you will put:
>
>
> User-agent: *
> Disallow: /FolderName
>
>
>
> On Thu, Aug 22, 2013 at 6:19 AM, Jim Giner  >wrote:
>
> > On 8/22/2013 8:05 AM, Curtis Maurand wrote:
> >
> >>
> >>
> >>
> >> Is the subdomain also in a subfolder of the main domain?
> >>
> >> Jim Giner wrote:
> >>
> >>> I have a main domain (of course) and a sub
> >>>
> >> domain.  I'm really trying to
> >>
> >>> steer my personal stuff away from
> >>>
> >> the main one and have focused all of
> >>
> >>> my php development to the
> >>>
> >> sub-domain.
> >>
> >>>
> >>> Lately I noticed that google catalogs my
> >>>
> >> sub-domain site stuff under the
> >>
> >>> main domain name and the links
> >>>
> >> that come up lead to that domain name
> >>
> >>> with the path that takes
> >>>
> >> the user to the sub-domain's home folder and
> >>
> >>> beyond.
> >>>
> >>>
> >>  Is there something that php (apache??) can do to control either
> >>>
> >> google's
> >>
> >>> robots or the user's view (url) so that it appears as a
> >>>
> >> page of my
> >>
> >>> sub-domain?  I'm really new at this stuff and know
> >>>
> >> nothing.  I'm lucky
> >>
> >>> that google is even finding my site!
> >>>
> >>> IN advance - I apologize for this off-topic question,
> >>>
> >> but this place is
> >>
> >>> a source of much knowledge, so I just threw in
> >>>
> >> a quick interlude here to
> >>
> >>> pick someone's brain.  :)
> >>>
> >>>
> >>  --
> >>> PHP General Mailing List (http://www.php.net/)
> >>> To unsubscribe, visit: http://www.php.net/unsub.php
> >>>
> >>>
> >>>
> >>  Yes - the sub is an add-on domain to my primary domain.  Hence the
> > overlap and problem.
> >
> >
> > --
> > PHP General Mailing List (http://www.php.net/)
> > To unsubscribe, visit: http://www.php.net/unsub.php
> >
> >
>
>
> --
>
> Willie Matthews
> matthews.wil...@gmail.com
>



-- 
Thank you,

Dan

Cell:  484-459-2856





Re: FW: [PHP] Accessing Files Outside the Web Root

2013-03-13 Thread Dan McCullough
Web bots can ignore the robots.txt file, most scrapers would.
On Mar 13, 2013 4:59 PM, "Jen Rasmussen"  wrote:

> -Original Message-
> From: Dale H. Cook [mailto:radiot...@plymouthcolony.net]
> Sent: Wednesday, March 13, 2013 3:38 PM
> To: php-general@lists.php.net
> Subject: [PHP] Accessing Files Outside the Web Root
>
> Let me preface my question by noting that I am virtually a PHP novice.
> Although I am a long-time webmaster, and have used PHP for some years to
> give visitors access to information in my SQL database, this is my first
> attempt to use it for another purpose. I have browsed the mailing list
> archives and have searched online but have not yet succeeded in teaching
> myself how to do what I want to do. This need not provoke a lengthy
> discussion or involve extensive hand-holding - if someone can point to an
> appropriate code sample or online tutorial that might do the trick.
>
> I am the author of a number of PDF files that serve as genealogical
> reference works. My problem is that there are a number of sites which are
> posing as search engines and which display my PDF files in their entirety
> on
> their own sites. These pirate sites are not simply opening a window that
> displays my files as they appear on my site. They are using Google Docs to
> display copies of my files that are cached or stored elsewhere online. The
> proof of that is that I can modify one of my files and upload it to my
> site.
> The file, as seen on my site, immediately displays the modification. The
> same file, as displayed on the pirate sites, is unmodified and may remain
> unmodified for weeks.
>
> It is obvious that my files, which are stored under public_html, are being
> spidered and then stored or cached. This displeases me greatly. I want my
> files, some of which have cost an enormous amount of work over many years,
> to be available only on my site. Legitimate search engines, such as Google,
> may display a snippet, but they do not display the entire file - they link
> to my site so the visitor can get the file from me.
>
> A little study has indicated to me that if I store those files in a folder
> outside the web root and use PHP to provide access they will not be
> spidered. Writing a PHP script to provide access to the files in that
> folder
> is what I need help with. I have experimented with a number of code samples
> but have not been able to make things work. Could any of you point to code
> samples or tutorials that might help me? Remember that, aside from the code
> I have written to handle my SQL database I am a PHP novice.
>
> Dale H. Cook, Member, NEHGS and MA Society of Mayflower Descendants;
> Plymouth Co. MA Coordinator for the USGenWeb Project Administrator of
> http://plymouthcolony.net
>
>
> --
> PHP General Mailing List (http://www.php.net/) To unsubscribe, visit:
> http://www.php.net/unsub.php
>
>
> Have you tried keeping all of your documents in one directory and blocking
> that directory via a robots.txt file?
>
> Jen
>
>
>
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>


Re: [PHP] Your Amazon.com order confirmation.

2012-06-08 Thread Dan McCullough
I was hoping for a TV

On Fri, Jun 8, 2012 at 10:19 AM, <> wrote:

>   Your Order with Amazon.com
>
>Thanks for your order,
> php-db-h...@lists.php.net!Did you know you can
> view and edit your  orders online, 24 hours a day?
> Visit Your Account.
>
>Order Information:
>
>
>   E-mail
> Address:   php-db-h...@lists.php.net
>
>
>BillingAddress:
> Av.
>GAHANNAUnited States
>  Phone: 1-747-517-7595
>
>
>
>   Order Grand
>  Total:  $60.99
>
>
>
>
>
>  Earn 3%
> rewards on yourAmazon.com orders with
> the AmazonVisa Card. Learn
>  More
>
>
> Order Summary:
>
>
>   Details:
>
>
>
>   Order #:
>  Y09-7318668-6213012
> Subtotal of items:
>  $ 60.99
>
> --
>   Total before tax:
>$ 60.99
>
> Tax Collected:
>$0.00
> --
>
>   Grand Total:
>$ 60.00
>   Gift Certificates:
>$ 0.99
>
> --
>   Total for this
>Order:$ 60.99
>
> The
> following item is auto-delivered to your  Kindle or
> other device. You can view more  information about
> this order by clicking on  the title on the Manage
> Your Kindle page at Amazon.com.
>
>The Witness by
>  Nora Roberts [Kindle Edition] $ 60.99
>  Sold By: Random House
>Digital, Inc.
>
>  You can review
> your orders in Your Account.  If you've explored
> the links on that page but  still have a question,
> please visit our online  Help Department.
>  Please note: This e-mail was sent from
> a  notification-only address that cannot accept
>  incoming e-mail. Please do not reply to this
>message.Thanks again for shopping
> with us.Amazon.com
>Earth's Biggest SelectionPrefer
> not to receive HTML mail? Click here
>




-- 
Thank you,

Dan

Cell:  484-459-2856





Re: [PHP] Upload using FTP commands

2010-08-26 Thread Dan McCullough
Take a look here:
http://us.php.net/manual/en/ref.ftp.php

You might have some issues with the memory limit in PHP so that might have
to be boosted for 20MB files.

On Thu, Aug 26, 2010 at 12:24 PM, Matthew Croud wrote:

>
> Hi,
>
> I want to give my client the ability to upload large files ( around 20MB )
> to a webspace.
> I reckon that using the FTP commands of PHP would be the best bet, but is
> it possible to allow them to do this through an online form.
>
> This is my vision: the client logs in to a form that has an upload button,
> and the upload button uses the FTP commands to upload the file.
>
> Is that do-able in PHP ?
>
> Cheers!
>
>
>
>
>
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>


Re: [PHP] blog design issue...

2010-03-20 Thread Dan McCullough
Table is the way to go for all the reasons that Rob mentioned.

>
>  This is going to be a small blog to start, but I guess I should always  be
>> looking at performance, security, & maintainability right?
>>
>
>
Good way to start is start small and build a strong base around a good
database, good performance practices and tight security you can then build
the cool features as you see fit.

Good thing about performance and security is that there are a ton of site
that outline best practices which means you wont have to re-invent the
wheel.

GL


Re: [PHP] Change styling depending on var value

2009-11-20 Thread Dan McCullough
To add to what Ashley said about $row[3],  remember that when you are
returning from the db the counter for fields will start at 0 not 1, so if
its the 3rd field that will be $row[2].  You might also want to do switch
rather then elseif but thats always a good debate.

On Fri, Nov 20, 2009 at 3:16 PM, Ashley Sheridan
wrote:

> On Fri, 2009-11-20 at 15:11 -0500, Phil Matt wrote:
>
> > Ashley Sheridan wrote:
> >
> > > Well, you're main problem here is that you are only using a single =
> > > character. What that is saying to PHP is: "if you let me assign the
> > > value of $beverage to $row[3] then do this next bit", but what I think
> > > you wanted it to say was "if $row[3] is the same as $beverage then do
> > > this next bit", which would need == instead of =
> > >
> >
> > Thanks, Ashley. I don't do enough PHP to get used to the syntax.
> >
> > I changed the operators to ==, but my conditional apparently isn't
> > working correctly. I checked to make sure the values in the cells were
> > the strings as I've specified them, but the resultant formatting always
> > defaults to the ELSE color.
> >
> > Must be something very simple, but I'm just not getting it.
> >
> > Cheers --- Phil
>
>
> Don't forget to reply to all!
>
> Just a quick question, what do you get if you do:
>
> print $row[3];
>
> Does it contain a string like you expect?
>
> Thanks,
> Ash
> http://www.ashleysheridan.co.uk
>
>
>


Re: [PHP] What PHP version are you using?

2009-10-29 Thread Dan McCullough
Like Israel it depends on the client I am doing several projects for a
client now that the hosting company is still using 4.0.6 - and its been a
headache.  Most of the personal projects and many of my other clients are on
5.1 or higher.

On Thu, Oct 29, 2009 at 12:22 PM, Tom Barrett  wrote:

> 2009/10/29 Israel Ekpo 
>
> > Hi Guys,
> >
> > I just want to conduct a quick survey to find out what version of PHP
> > people
> > are using in their production environments.
> >
> > I have a PHP extension for Solr that I have set the minimum required
> > version
> > as 5.2.11.
> >
> [snip]
>
> > I cannot go below 5.2.0 though but I am thinking about starting at 5.2.4
> > and
> > newer.
> >
> > I would really appreciate some feedback as it will be useful in helping
> me
> > determine which PHP version numbers to do my regression tests against.
> >
>
> > cat /etc/redhat-release
> Red Hat Enterprise Linux Server release 5.3 (Tikanga)
>
> > php -v
> PHP 5.1.6 (cli) (built: Feb 26 2009 07:01:12)
> Copyright (c) 1997-2006 The PHP Group
> Zend Engine v2.1.0, Copyright (c) 1998-2006 Zend Technologies
>
> > yum list php
> Loaded plugins: downloadonly, rhnplugin, security
> Excluding Packages in global exclude list
> Finished
> Installed Packages
> php.x86_64
> 5.1.6-23.2.el5_3
> installed
>
> I wouldn't have thought this to be too uncommon.
>
> HTH
>


Re: [PHP] Web Service Server in PHP

2009-10-21 Thread Dan McCullough
I believe NuSoap is still available
source: http://sourceforge.net/projects/nusoap/
http://greghuet.blogspot.com/2007/12/soap-php5-and-nusoapphp.html

You can also look here at PHPs SOAP functions
http://php.net/manual/en/refs.webservice.php

On Wed, Oct 21, 2009 at 9:26 PM, Daniel Echalar  wrote:

> Hi,
>
> Does anybody knows a web services server based on PHP?
>
> The only one a see is Nusoap, but even for this one i can't find the
> webpage
> to see the documentation.
>
> by the way, i'm trying to develop an application using web services in PHP,
> any start point suggestion will be appreciated.
>
> thanks for the anwers!
>


Re: [PHP] Printing

2008-12-17 Thread Dan McCullough
I did something similar, but it was some work I did for a company and the
application was an internal application that used PHP and a Java applet to
send the file to a workers local printer since it cant be accomplished by
PHP itself.

On Wed, Dec 17, 2008 at 3:30 PM, Dan Shirah  wrote:

> >
> >   You can't, the best you can do is send the PDF down and let the user
> >> choose to do with it what they will
> >
> >
> >
> > --
> >
> > Bastien
> >
>
> So you think I should try and look into a way to have FPDF append each
> document to the already created document, and once all pages have been
> added
> to the PDF force it back to the user to open in the broswer?
>


Re: [PHP] Project Management

2007-05-24 Thread Dan McCullough

On 5/24/07, Christian Haensel <[EMAIL PROTECTED]> wrote:

Hi Edward,

thanks for your comment. I use a lab book too... And already fille two of
them in the last 8 weeks  I just wanna use the project management thing
to collect my ideas, and write a howto for "future generation developers"
who may have to deal with this thing once I am gone.

Stut,

yes sir, I've used google and had a look at those things. What I wanted was
to know what you guys use. There is nothing more valuable than the opinions
of other developers and to know what they use in their day to day job.

Anyhow, my arse is still on... so I better bugger off :oP

Cheers for your comments!

Chris



- Original Message -
From: "Edward Kay" <[EMAIL PROTECTED]>
To: 
Sent: Thursday, May 24, 2007 12:00 PM
Subject: RE: [PHP] Project Management


>
>
>> -Original Message-
>> From: Christian Haensel [mailto:[EMAIL PROTECTED]
>> Sent: 24 May 2007 10:27
>> To: php-general@lists.php.net
>> Subject: [PHP] Project Management
>>
>>
>> Morning guys,
>>
>> this is not exactly a PHP question, but as I am sure that I am talking to
>> more or less professional developers, I thought I might ask you.
>>
>> As I am working on some... well, for my standards... huge
>> project, I thought
>> that some kind of project management software would / could be helpful to
>> keep track of my ideas, tasks and so on. Right now I am using a
>> huge chunk
>> of papers to keep track (as good as I can).
>>
>> Has any of you any experience with good project management software? Best
>> would be OpenSource, of course :o) My boss doesn't want to spend a lot of
>> money ;o)
>>
>> Cheers guys,
>>
>> Chris from sunny germany
>
>
> If you're working on your own, I would think realistically about how much
> you would use such software. I've used Basecamp, Trac, MS Project and
> others
> in the past and find them a waste of time. My favourite tool is simply an
> A4
> lab book. (I know this doesn't scale, but it fits the bill perfectly for
> now).
>
> For initial brainstorming/idea tracking, I do use FreeMind though.
> http://freemind.sf.net
>
> HTH, Edward
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Creating a table for login system

2007-05-03 Thread Dan McCullough

http://www.devshed.com/c/a/PHP/Logging-With-PHP/

enjoy!

On 3 May 2007 18:38:02 GMT, Karl James <[EMAIL PROTECTED]> wrote:

Team,

Can you provide a very accurate tutorial on how to create a login system.
I am using website to control a fantasy football league and teams.
one sign in only for each league member/team owner.

I am using phpmyadmin.

Can you please help me with how the table should be.

Also, help provid a script for registering and logging in.


my site that i will be using this for is www.theufl.com
Check it out.

Thanks, Karl

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Staff log-in

2006-11-10 Thread Dan McCullough

I do a lot of work for "non-profits" a lot of them are really good
clients, pay well and on time, but I know most of them pretty well and
know that they are truly "non-profits", so just because you said you
were a non-profit where we supposed to assume that you wanted it for
free and supported forever.

On 11/10/06, tedd <[EMAIL PROTECTED]> wrote:

At 7:16 PM + 11/9/06, Brynjar GuĂ°nason wrote:
>Hi,
>
>I need a little php script. Staff log in by entering username and password
>and then the next time they enter their username and password they log out.
>The script has to take down the time they log in and log out. Then I should
>be able to read old log-ins and log-outs.
>
>I unfortunately can't make it myself because I don't have the knowledge, can
>anyone of you do this for me? It's for a small non-profit orginisation.
>
>Thanks in advance,
>Brynjar Gudnason.

Brynjar:

You say a "little php script" -- if you have no
knowledge of how to do this, then what makes you
think it's little? Stop and think dude -- you're
asking for code that will keep track of users,
passwords, deal with what happens if they lose
their password, keeping passwords secure, keeping
track of times on/off, and writing an admin to
review/edit times and edit users (add, delete,
ban) --this is not a little script.

Lastly, I think we all know that "non-profit"
simply means that at the end of the year you get
to roll your profits over to the next year
without incurring taxes on the excess. Nothing
more.

Plus, there's no limit or requirements as to the
amount/percentage you pay yourself as compared to
what amounts you apply to your "cause". So,
mentioning "non-profit" to me is like saying
you're just another scam -- and one, who's
trolling for free php services.

tedd

--
---
http://sperling.com  http://ancientstones.com  http://earthstones.com

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Remote Robot Control with PHP

2006-10-31 Thread Dan McCullough

Cool!

On 10/31/06, Prathaban Mookiah <[EMAIL PROTECTED]> wrote:

Hello List,

I thought of sharing my experience of writing a controller to remotely
control a robot through a webserver using PHP. Though I could not use PHP
alone to do the entire job due the high delay it takes to connect to the
telnet port on the robot, (I adopted the PHPTelnet class written by Antone
Roundy - http://www.geckotribe.com/php-telnet/), I could not resist using it
for some part of the application.

So the model I used for my purpose is this:

Browser -> WebServer  -> Java  > Robot
  AJAX  PHP

I used PHP to communicate between the Java program which I run in the
background and the AJAX calls from the browser. This setup works fine for my
purposes and satisifies the strict time constraints.

If someone has a better idea of implementing this thing in PHP, please do let
me know your comments.

There is a lot more to do in this project and I hope to make use of PHP a lot
along the way. This is a NSF funded project and this work will be published
in some leading journals. What I am excited about is the prospect of putting
in a word about PHP in these journals, since as far as I know, it is not too
well known in the academic circles.

Regards,

Prathap

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Shopping cart

2006-08-22 Thread Dan McCullough

Another thing to remember is that you dont want to get overwhelmed
with all the work when you are going to build your own, a list of
250,000 features will never get done, many have tried, many have
failed, so plan what you need to start with and build the other
features later.

On 8/22/06, Dan McCullough <[EMAIL PROTECTED]> wrote:

I believe you can find those out there as well, most of what you need
will be available out there, you will be able to find them and then
take what you need to work it into your cart, probably would be a good
idea to think of all the different pieces and then find the different
examples/tutorials/snippets and then see how they fit.

On 8/22/06, Ryan A <[EMAIL PROTECTED]> wrote:
> Hey,
>
> > There are many payment processing
> > script/classes/examples available
> > that you could use.  Just google around for your
> > gateway provider,
> > like PHP and Authorize.net, etc, or go to their site
> > and look for a
> > developer, API or something like that to see if they
> > have done some
> > examples.
>
> Yeah, i guess thats also an idea, will look into it.
>
> Will also need to look into the logic of calculating
> shipping, something that I have never done in the
> past.
>
> Kind of worked out the logic of "customers who bought
> this also bought..." gotto take one step at a time...
> which breaks down to a problem coz dont have much time
> to take many steps :(
>
> Cheers!
> Ryan
>
> --
> - The faulty interface lies between the chair and the keyboard.
> - Creativity is great, but plagiarism is faster!
> - Smile, everyone loves a moron. :-)
>
> __
> Do You Yahoo!?
> Tired of spam?  Yahoo! Mail has the best spam protection around
> http://mail.yahoo.com
>



--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Shopping cart

2006-08-22 Thread Dan McCullough

I believe you can find those out there as well, most of what you need
will be available out there, you will be able to find them and then
take what you need to work it into your cart, probably would be a good
idea to think of all the different pieces and then find the different
examples/tutorials/snippets and then see how they fit.

On 8/22/06, Ryan A <[EMAIL PROTECTED]> wrote:

Hey,

> There are many payment processing
> script/classes/examples available
> that you could use.  Just google around for your
> gateway provider,
> like PHP and Authorize.net, etc, or go to their site
> and look for a
> developer, API or something like that to see if they
> have done some
> examples.

Yeah, i guess thats also an idea, will look into it.

Will also need to look into the logic of calculating
shipping, something that I have never done in the
past.

Kind of worked out the logic of "customers who bought
this also bought..." gotto take one step at a time...
which breaks down to a problem coz dont have much time
to take many steps :(

Cheers!
Ryan

--
- The faulty interface lies between the chair and the keyboard.
- Creativity is great, but plagiarism is faster!
- Smile, everyone loves a moron. :-)

__
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around
http://mail.yahoo.com



--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Shopping cart

2006-08-22 Thread Dan McCullough

Commercial product that is good http://www.x-cart.com/


On 8/22/06, Ryan A <[EMAIL PROTECTED]> wrote:

It really looks like I will have to write this myself
:(

I know it will be good for experience but like someone
else has pointed out, I would rather work with someone
elses code for the payment parts knowing that it has
been totally debugged than getting screwed later on
because I missed assigning a value to a variable...

Still searching though, tested OSC,ZenCart,
Xcart,FishCart, now on to phpshop...

Drupal seems good, but kinda large with all the
modules out there... a bit intimidating, will keep
that as a "reserve check"

I think this is the reason why there are so many
"carts " out there people just get pissed seaching for
a simple one which they can use their _own_ page
design, and dont find it... then they write one for
themselves, see it works very well, decide to go
commercial... get requests to add "just one more
thing" and screw it up like all the others..!

Cheers!
Ryan

--- Larry Garfield <[EMAIL PROTECTED]> wrote:

> There may be other canned solutions that are not as
> bad as OSCommerce.  It's
> the only one I've worked with other than Drupal.
> I've worked with Drupal
> extensively, but haven't used its ecommerce modules
> extensively.
>
> But yes, I highly recommend OSCommerce as an example
> of how not to write a PHP
> application, of any kind.
>
> On Monday 21 August 2006 15:18, Gerry D wrote:
> > So if I understand you gentlemen correctly, these
> pre-builds serve as
> > examples how NOT to do it?
> >
> > Gerry
> >
> > On 8/20/06, Larry Garfield
> <[EMAIL PROTECTED]> wrote:
> > > On Sunday 20 August 2006 20:17, Gerry D wrote:
> > > > On 8/19/06, Larry Garfield
> <[EMAIL PROTECTED]> wrote:
> > > > > OSCommerce is crap.  Don't bother.
> > > >
> > > > Why do you say that, Larry? I may want to get
> into an app like that
> > > > because I think one of my clients is ready for
> it. What are the cons,
> > > > and what are my options? What are Drupal's
> limitations?
> > >
> > > I tried using it for a client last summer,
> because it was available free
> > > on the client's web host.  It is extremely
> rigid.  If you want a program
> > > that works the way they want and looks kinda
> like Buy.com with a
> > > table-based layout in 3 columns with certain
> visual effects, it's fine.
> > > If you want to change or customize anything,
> good luck.  Nearly
> > > everything is hard coded with HTML and
> presentation PHP and business
> > > logic PHP all mixed in together. With a table
> based layout.
> > >
> > > Ugh.
> > >
> > > As for using pre-build vs. rolling your own, the
> main reason I favor
> > > ready-made is the bank hookups.  Anytime
> financial stuff is involved, I'd
> > > rather use something someone else already
> debugged than roll my own.
>
> --
> Larry GarfieldAIM: LOLG42
> [EMAIL PROTECTED]ICQ: 6817012
>
> "If nature has made any one thing less susceptible
> than all others of
> exclusive property, it is the action of the thinking
> power called an idea,
> which an individual may exclusively possess as long
> as he keeps it to
> himself; but the moment it is divulged, it forces
> itself into the possession
> of every one, and the receiver cannot dispossess
> himself of it."  -- Thomas
> Jefferson
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>


--
- The faulty interface lies between the chair and the keyboard.
- Creativity is great, but plagiarism is faster!
- Smile, everyone loves a moron. :-)

__
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around
http://mail.yahoo.com

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Shopping cart

2006-08-22 Thread Dan McCullough

There are many payment processing script/classes/examples available
that you could use.  Just google around for your gateway provider,
like PHP and Authorize.net, etc, or go to their site and look for a
developer, API or something like that to see if they have done some
examples.

On 8/22/06, Ryan A <[EMAIL PROTECTED]> wrote:

It really looks like I will have to write this myself
:(

I know it will be good for experience but like someone
else has pointed out, I would rather work with someone
elses code for the payment parts knowing that it has
been totally debugged than getting screwed later on
because I missed assigning a value to a variable...

Still searching though, tested OSC,ZenCart,
Xcart,FishCart, now on to phpshop...

Drupal seems good, but kinda large with all the
modules out there... a bit intimidating, will keep
that as a "reserve check"

I think this is the reason why there are so many
"carts " out there people just get pissed seaching for
a simple one which they can use their _own_ page
design, and dont find it... then they write one for
themselves, see it works very well, decide to go
commercial... get requests to add "just one more
thing" and screw it up like all the others..!

Cheers!
Ryan

--- Larry Garfield <[EMAIL PROTECTED]> wrote:

> There may be other canned solutions that are not as
> bad as OSCommerce.  It's
> the only one I've worked with other than Drupal.
> I've worked with Drupal
> extensively, but haven't used its ecommerce modules
> extensively.
>
> But yes, I highly recommend OSCommerce as an example
> of how not to write a PHP
> application, of any kind.
>
> On Monday 21 August 2006 15:18, Gerry D wrote:
> > So if I understand you gentlemen correctly, these
> pre-builds serve as
> > examples how NOT to do it?
> >
> > Gerry
> >
> > On 8/20/06, Larry Garfield
> <[EMAIL PROTECTED]> wrote:
> > > On Sunday 20 August 2006 20:17, Gerry D wrote:
> > > > On 8/19/06, Larry Garfield
> <[EMAIL PROTECTED]> wrote:
> > > > > OSCommerce is crap.  Don't bother.
> > > >
> > > > Why do you say that, Larry? I may want to get
> into an app like that
> > > > because I think one of my clients is ready for
> it. What are the cons,
> > > > and what are my options? What are Drupal's
> limitations?
> > >
> > > I tried using it for a client last summer,
> because it was available free
> > > on the client's web host.  It is extremely
> rigid.  If you want a program
> > > that works the way they want and looks kinda
> like Buy.com with a
> > > table-based layout in 3 columns with certain
> visual effects, it's fine.
> > > If you want to change or customize anything,
> good luck.  Nearly
> > > everything is hard coded with HTML and
> presentation PHP and business
> > > logic PHP all mixed in together. With a table
> based layout.
> > >
> > > Ugh.
> > >
> > > As for using pre-build vs. rolling your own, the
> main reason I favor
> > > ready-made is the bank hookups.  Anytime
> financial stuff is involved, I'd
> > > rather use something someone else already
> debugged than roll my own.
>
> --
> Larry GarfieldAIM: LOLG42
> [EMAIL PROTECTED]ICQ: 6817012
>
> "If nature has made any one thing less susceptible
> than all others of
> exclusive property, it is the action of the thinking
> power called an idea,
> which an individual may exclusively possess as long
> as he keeps it to
> himself; but the moment it is divulged, it forces
> itself into the possession
> of every one, and the receiver cannot dispossess
> himself of it."  -- Thomas
> Jefferson
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>


--
- The faulty interface lies between the chair and the keyboard.
- Creativity is great, but plagiarism is faster!
- Smile, everyone loves a moron. :-)

__
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around
http://mail.yahoo.com

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Re: Recommendations for PHP debuggers?

2006-08-21 Thread Dan McCullough

How is this different then what they try and sell you for $249.  I
have eclipse for Java development, and was looking at Zends package
for PHP development, but if they are basically selling me the same
thing then I would go with eclipse.

On 8/21/06, Colin Guthrie <[EMAIL PROTECTED]> wrote:

Larry Garfield wrote:
> I'm watching this thread closely myself, as I'd love something to use at home
> (on Linux) that doesn't cost what Zend does. :-)  Currently I use PHPeclipse,
> but it is frankly not that good (the code assistance feature is rudimentary
> at best), and I've not setup the debugger yet.  That, and Eclipse itself is
> just a dog slow memory hog.

Did you look at this? I posted it earlier and although I've not hooked
up the debugger, AFAIK it's free (but provided by Zend), so it should
suit you nicely (except that you'll still need that extra gig of ram to
run eclipse ;))

http://www.zend.com/phpide/

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Zend Studio, phpMyAdmin, and mysql.sock

2006-07-14 Thread Dan McCullough

in phpmyadmin config.default.php you can specify the socket that it
should be looking for. have you tried that?

On 7/14/06, Dave M G <[EMAIL PROTECTED]> wrote:

David Tulloh,
> This sounds like a Zend Studio problem and question.
> It could possibly be a MySQL or even a phpMyAdmin question.
> It doesn't really have anything to do with PHP.
>
I realize that Zend Studio is separate from PHP, but I would hardly go
so far as to say it has "nothing to do with PHP". Zend is the company
that *makes* PHP. Zend is a development environment for creating PHP.

So I don't think it's at all unreasonable to think that maybe there are
people here who use it (or even develop it) on this list.

And I do realize that Zend has its own forum, and I have posted there.
But the question has gone for days without response, so I'm broadening
my search.

What else should one do when one gets no response in a more specific forum?
> You paid Zend for the product, ask them how it works.
>
Well, what I have is the trial version, which they say they support, but
they have not responded to my email sent to them. So I don't know if I'm
far down the priority list for not having paid yet or if they just
usually take days to answer or what.

In any case, this list is called PHP "general". Am I really so
unreasonable in thinking that asking about how to set up a PHP
development environment so that I can debug my PHP scripts without it
conflicting with the PHP database administration system is on-topic?

--
Dave M G

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] url obfuscation

2006-07-13 Thread Dan McCullough

For me it doesnt matter I dont want Google in the section that I'm obfuscation.

On 7/13/06, Richard Lynch <[EMAIL PROTECTED]> wrote:

On Fri, July 7, 2006 10:56 pm, Anas Mughal wrote:
> My URLs are constant. They are not changing.
> All my dynamic pages are indexed nicely on Google.
>
> I agree that a computerized screen scrapper could still screen scrap
> most of
> my site. However, a simple script that attempts to bump up the
> identifier of
> a resource in a URL, would not work. Here is example:
>
> http://mydomain.com/view_resource.php?id=1
> http://mydomain.com/view_resource.php?id=2
> http://mydomain.com/view_resource.php?id=3
> http://mydomain.com/view_resource.php?id=4
>
> That would not work because my IDs are not sequential.
>
> Any thoughts...

Do your other pages link to the pages?

Because I don't need to PREDICT the URLs, just follow them from page
to page.

That's pretty much how a search engine works.

If you really want to stop a web-scraper, you pretty much have to
accept that you'll not be listed in Google (et al) as well.

--
Like Music?
http://l-i-e.com/artists.htm

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Debugging Log

2006-07-12 Thread Dan McCullough

Ahh yes I do that as well, I knew there was another other then syslog.

On 7/12/06, Jochem Maas <[EMAIL PROTECTED]> wrote:

Michael B Allen wrote:
> What is the standard method of logging debug info? Should I just fopen
> a file for append and write the message or is there a facility provided?

there is also error_log() (and the 'error_log' ini setting)
- I abuse it for debugging now and again.

>
> Mike
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Debugging Log

2006-07-12 Thread Dan McCullough

I wrote my own, very simple, very easy.  I think the code is in the
archive somewhere.  Otheres have written similar functions.

CODE +++

function logError ($logentry, $lgname) {
// simple function to log errors to text/log file.
$logfile = @fopen ($lgname, "a+");
 if (!$logfile) {
 echo ("\n\n ERROR: Failed to open $lgname\n\n");
 } else {
 fwrite ($logfile, "[".date ("D M d Y h:i:s")."] [$logentry]\n");
 fclose ($logfile);
 }
}

where you want to log

logError($username.' has successfully logged in.','account.log');

CODE +++

Lately I have been using the syslog from php.

On 7/12/06, KermodeBear <[EMAIL PROTECTED]> wrote:

http://pear.php.net/package/Log/ works well for me. Supports writing
messages to files, to a separate window via JavaScript, probably syslog as
well as a few others.

-Original Message-
From: Michael B Allen [mailto:[EMAIL PROTECTED]
Sent: Wednesday, July 12, 2006 2:02 PM
To: php-general@lists.php.net
Subject: [PHP] Debugging Log

What is the standard method of logging debug info? Should I just fopen
a file for append and write the message or is there a facility provided?

Mike

--
Michael B Allen
PHP Extension for SSO w/ Windows Group Authorization
http://www.ioplex.com/

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] PHP Bug Tracking

2006-07-06 Thread Dan McCullough

I just installed it so its fresh in my mind.

:)

On 7/6/06, Chris Hemmings <[EMAIL PROTECTED]> wrote:

Dan McCullough wrote:
> This one?
> http://dev.mysql.com/downloads/other/eventum/
>
> On 7/6/06, Chris Hemmings <[EMAIL PROTECTED]> wrote:
>
>> Can anyone point me in the direction where I can find a place to
>> download the bug track system that PHP/PEAR & PECL uses.  I seem to
>> remember it is available but can't find it anymore!
>>
>> Ta!
>>
>> Chris.
>>
>> --
>> PHP General Mailing List (http://www.php.net/)
>> To unsubscribe, visit: http://www.php.net/unsub.php
>>
>>
Cheers Dan,

Looks like the one :-)

http://www.mysqltalk.org/what-software-is-used-by-bugsmysqlcom-vt10767.html

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] PHP Bug Tracking

2006-07-06 Thread Dan McCullough

This one?
http://dev.mysql.com/downloads/other/eventum/

On 7/6/06, Chris Hemmings <[EMAIL PROTECTED]> wrote:

Can anyone point me in the direction where I can find a place to
download the bug track system that PHP/PEAR & PECL uses.  I seem to
remember it is available but can't find it anymore!

Ta!

Chris.

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] url obfuscation

2006-07-06 Thread Dan McCullough

Looking for a good way to obfuscation the name value pairs in a URL,
so it might be something like
http://www.domain.com/page=fjdsaflkjdsafkfjdsakfjdsalkfjsda983dsf or
something like that, I was looking at base64_encode, but was wondering
what others might do or use.  It doesnt have to be super secure, but I
would still like the information to not be really visable.

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Re: creating a threaded message system--sorting messages

2006-06-29 Thread Dan McCullough

I've come into this discussion pretty late so please bear with me if I
go over something that has been ruled out.

You are trying to print out in a threaded method the first post in a
thread followed by each post after that, that is a child/reply to that
post.  Is that correct?

So something like

Example 1

Thread1
 Post1
   Post2
 Post3
   Post4
 .

or

Example 2

Thread1
 Post1
   Post2 - reply to post 1
Post3 - reply to post 2
   Post4 - reply to post 1
   Post5 - reply to post 1
Post6 - reply to post 2
 Post7 - reply to post 3


Example 1 is very common and is the easiest to implement.  From what I
remember you would need a couple of DB tables for post, post_thread,
post_post, thread

So for your question thread isnt very relative but I thought I would
throw it in.

thread {
threadid int(11) auto_increment,
threadname
threadsort
...

thread_post {
threadid int(11)
postid int(11)


post {
postid int(11) auto_increment,
postname
posttext
...

post_post
postid int(11),
postid2 int(11)


Please note I have two kids fighting over the cat, trying to cook
dinner and stave off a flood of water from the rising river so the SQL
structure is for example.

You can get everything in one query from the DB and lay it out based
on the id of the post, if you DB is properly indexed and setup and
queries are optimized you'll hardly notice a blip when the load gets
up.  You do not want to be doing multiple queries on a page when one
well written query will do the trick.

Either way if this is more what you are looking for we can get into
specifics later.

Dan


On 6/29/06, KermodeBear <[EMAIL PROTECTED]> wrote:

Hello,

As Adam pointed out, this can be deadly to your database, especially as the
number of posts grows. If you want to go that route, I would recommend
selecting all the posts in that particular thread and sorting the data out
in PHP somehow. No need to slam your database with (potentially) hundreds of
queries to display a discussion. Multiply that by several page views at
once...

If you don't mind the extra work and investigation, I would recommend
downloading some PHP forum software that supports threaded discussion and
see how they implement it. I found several listed in DMOZ:
http://dmoz.org/Computers/Programming/Languages/PHP/Scripts/Forums/

Let us know what you come up with! I'd like to see how you work this out.
This is a good computer science type of problem with practical application -
the kind of stuff they should have taught me in school but never did. ~(o:

Best of luck,

-K.Bear

> , almost. I read the article suggested by K.Bear and found the
> recommended solution to be a bit more complicated than I wanted to
> implement. I then found another way to do this using the existing
> "Adjacency List Model" through a recursive function. So basically, you
> query the database for the post_id of the very first post in the
> discussion. You then call a function that displays that post, searches
> for all children of that post and then calls itself recursively on
> each of the children it discovers. This works great for spitting out
> the posts in the proper order. Now I'm trying to figure out how to
> make sure the indenting looks right in the browser.
>
> - Ben
>
>> Wouldn't that involve a separate SQL query for every post?

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Re: Update site through email

2006-06-29 Thread Dan McCullough

There are several blog software packages and cms packages that do
something like this you might want to download and take a peek.

Wordpress one that comes to mind.

On 6/29/06, Mathieu Dumoulin <[EMAIL PROTECTED]> wrote:

How i'd do it is not simple, i'm sure there is an easier method but here
goes for mine.

First you have to setup an inbox that you can read, it can be POP3 or
IMAP, as long as your PHP script can read it it's fine.

Second, create a script that can actually connect to that inbox and read
for a new message periodically. You can use a CRONJOB or a Scheduled
Task if it's available, else, you'll have to check the mailbox from time
to time when your page launches from a web browser (Try not to do it all
the time or your page will suffer from this process if it is launched
all the time).

That script will have to read the emails in the inbox, finds the
appropriate email and stores the content the way you want, database or
file, your choice.

Then, your web page will have to read from that stored source of your
choice and "echo" the content at it's right place.

As you can see, it CAN be done, it's just a strange way of doing it.

Furthermore i see problems to that. You can probably get very easily
hacked using this method. Its easy to read the incoming data in the
server, find the email address used to update the content and then send
a mail yourself. There is nothing you can do to stop that except encrypt
your email using SSL... But thats a bit hardcore and there are much
simpler ways than using SSL encrypted email to update a page ;)

Math

Rodrigo de Oliveira Costa wrote:
> Hy guys I'd like to know if there is a way to update a site through
> sending an email. Something like this, you send an email and the body
> of the email substitutes a text you use in your site. Igreat apreciate
> any help since I couldn't find anything on this topic.
>
> Thanks,
> doRodrigo

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] rss feeds from db

2006-06-22 Thread Dan McCullough

I'm having some problems where some undefined entity are getting in,
these entities are usually html entities.

sad thing is"¦bringing in these large chains is putting

the xml doc points to the & in ";¦" as the problem.  what do I
need to do to get this stuff cleaned up?

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] User Login Problem

2006-06-20 Thread Dan McCullough

Or make your own, might be easier to do.

On 6/20/06, suresh kumar <[EMAIL PROTECTED]> wrote:

Hi,
I am facing one problem in my project.i want to restrict more than one user 
login in the same account .Is there any functions available to check r we can 
implement using session.
   
A.suresh


-
 Yahoo! India Answers: Share what you know. Learn something new Click here
 Send free SMS to your Friends on Mobile from your Yahoo! Messenger Download now



--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] parsing/replacing for special MS Word characters

2006-05-24 Thread Dan McCullough

I have a friend who I wrote some very simple publishing software,
basically he takes his writtings and puts them online.  Well his
writtings are in Word and so he has alot of special characters that he
inputs, some unknowingly, into the database.  Are there any classes or
samples of what others have done to strip/replace/find these special
characters, I have asked him to be careful, but he will do it once or
twice and then forget and lapse, and I get a call saying can you help
me get these out.

Any ideas?

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] looking for shopping cart

2006-04-09 Thread Dan McCullough
X-Cart, ZenCart (osCommerce like),
http://www.hotscripts.com/PHP/Scripts_and_Programs/E-Commerce/index.html

if you look in the archives you will find similar questions with a lot
better response.

On 4/8/06, Lisa A <[EMAIL PROTECTED]> wrote:
> I need a shopping cart for a website that once I install and set up, my
> client can easily add merchandise to it.  They use Paypal.  It has to be
> very easy for them to upload images and products, prices, etc.
> If anyone knows of something, please let me know.
> I host my own websites, so not interested in paying a monthly fee.
> thanks,
> Lisa
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] php security

2006-04-06 Thread Dan McCullough
Cool Chris I'm going to take a look at that movie.   Dallas there is a
section at the top of the ini file that lists some directives and
their status to address security or performance issues, but as Chris
mentioned your code could be as big of a risk as anything so pay
attention to that.

On 4/6/06, Chris Shiflett <[EMAIL PROTECTED]> wrote:
> Dallas Cahker wrote:
> > I was looking to see if there was a quick checklist of settings
> > for php to be disabled/enabled in the ini file to make the
> > application more secure.
>
> Although there are some directives worth disabling (register_globals,
> magic_quotes_gpc, allow_url_fopen), most vulnerabilities in PHP
> applications are a result of flaws in the PHP code. There are no magic
> php.ini configuration directives that can make your applications secure
> - not that you were suggesting this, but it's woth explicitly stating.
>
> A couple of years ago, I tried to summarize several good practices into
> a single mantra - filter input, escape output (FIEO). These practices
> don't eliminate everything, but they're a very good first step and can
> provide a solid foundation for secure PHP programming.
>
> I made a movie (webcast, screencast, or whatever you call them) about
> auditing PHP applications, and it also covers filtering input and
> escaping output:
>
> http://brainbulb.com/php-security-audit-howto.mov
>
> There's also the PHP Security Guide:
>
> http://phpsec.org/projects/guide/
>
> We're in the process of writing a second version of the guide, in order
> to address the following shortcomings:
>
> 1. The guide is several years old, so some techniques have been refined
> and/or simplified in the meantime.
> 2. The vocabulary is slightly inconsistent with the rest of the industry
> in some cases.
> 3. Not all major areas are covered, so it is incomplete.
> 4. Some explanations are ambiguous and can yield misinterpretations.
>
> Lastly, I want to point out two of the primary attacks that are not
> prevented with FIEO:
>
> 1. Cross-Site Request Forgeries (CSRF)
> 2. Session Fixation
>
> Hope that helps get you started.
>
> Chris
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] php security

2006-04-06 Thread Dan McCullough
php.ini-anal-retentive-paranoid.

I'm editing mine for that right now, everything is off, the sever has
a keyboard, mouse, monitor no cd/dvd, no floppy, no usb and is
unplugged from the network, there are 6 security guards that surround
you and they give you 5 minutes on a timer.

On 4/6/06, Kevin Kinsey <[EMAIL PROTECTED]> wrote:
> Dallas Cahker wrote:
>
> >I was looking to see if there was a quick checklist of settings for php to
> >be disabled/enabled in the ini file to make the application more secure.
> >I'm making sure the apps we come out with dont allow sql injections, or form
> >injections and so forth, I have just seen some posts about magic quotes and
> >so on and so I was curious.
> >
> >
>
>
> Well, generally php comes with a "php.ini-dist" and a "php.ini-recommended";
> for tighter security, use the "recommended" version.  Examining a diff
> of the
> files could help shed some light, as well.
>
> Of course, some of us could be waiting for the day when they ship with a
> "php.ini-ironclad", "php.ini-stealthmode", or
> "php.ini-anal-retentive-paranoid",
> but I'm not sure those are slated, even for PHP6  ;-)
>
> HTH,
>
> Kevin Kinsey
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] server/PHP security

2006-04-06 Thread Dan McCullough
WHat types of files were they, if you dont mind me asking?

On 4/6/06, Wolf <[EMAIL PROTECTED]> wrote:
> I woke up on thanksgiving morning to find my server hacked through a
> hole left by a file upload area of my site.  I restored the backup and
> placed a few blocks in place on the server, so they can get in, but they
> can't get out  ;)
>
> What I am interested in finding out is what the best way is to make sure
> that I can rework the upload area to allow upload and download from it
> while keeping script kiddies from exploiting it again.
>
> I can post the scripts (if you are interested in pulling them apart or
> such) as I have accumulated 3 different versions now, but I am wondering
> what you guys use currently as "standard" PHP security and still do file
> parsing and such.
>
> Thanks,
> Wolf
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] server/PHP security

2006-04-06 Thread Dan McCullough
http://www.hardened-php.net/advisory_202005.79.html

check this out

On 4/6/06, Wolf <[EMAIL PROTECTED]> wrote:
> I woke up on thanksgiving morning to find my server hacked through a
> hole left by a file upload area of my site.  I restored the backup and
> placed a few blocks in place on the server, so they can get in, but they
> can't get out  ;)
>
> What I am interested in finding out is what the best way is to make sure
> that I can rework the upload area to allow upload and download from it
> while keeping script kiddies from exploiting it again.
>
> I can post the scripts (if you are interested in pulling them apart or
> such) as I have accumulated 3 different versions now, but I am wondering
> what you guys use currently as "standard" PHP security and still do file
> parsing and such.
>
> Thanks,
> Wolf
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] php security

2006-04-06 Thread Dan McCullough
I would look here for an idea.  http://phpsec.org/projects/guide/
I think you'll find many opinions on the matter.  One thing to
remember is that once the app goes live your job doesnt stop there
you'll need to be just as stringent about security and checking logs
and errors as you were when you were developing.

On 4/6/06, Dallas Cahker <[EMAIL PROTECTED]> wrote:
> I was looking to see if there was a quick checklist of settings for php to
> be disabled/enabled in the ini file to make the application more secure.
> I'm making sure the apps we come out with dont allow sql injections, or form
> injections and so forth, I have just seen some posts about magic quotes and
> so on and so I was curious.
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] style

2006-04-06 Thread Dan McCullough
Short tags in the php.ini file.


On 4/6/06, Dallas Cahker <[EMAIL PROTECTED]> wrote:
> What is that called and where in the php.ini file do I enable it?  Sorry if
> this is a stupid question but since I dont know what its called it makes it
> difficult to google it.
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] help with some logic.

2006-04-04 Thread Dan McCullough
hey Dallas,

have you thought about breaking this up and making two seperate
functions one the checks the cookie and one that checks the session
information?  I'm not sure if that is what you were looking for as far
as an answer but it might be a good start.

On 4/4/06, Dallas Cahker <[EMAIL PROTECTED]> wrote:
> I've been looking at this code for a few hours now and I get the nagging
> feeling that I am overcomplicating something, something I never ever do.  I
> have a login that puts some information on the session, and if the customer
> wants they can ask to be remembered, the cookie is given the customers user
> name and another cookie stores a unique id, similar to a password I could do
> the password in a cookie as its md5 encrypted, but I went with an a unique
> id which is store in the user db.
>
> Anyway here is what I am trying to do with the code below.  The authorized
> user section requires 4 pieces of information, userid, password, username
> and user level, a person who logs in each time gets that information
> assigned to their session, that part works *knock on wood* perfectly.  When
> a customer says "remember me" they go away and come back a while later they
> are remembered, so that part works perfectly, however I need to get the
> persons information and put that on the session, however I would like the
> function to behave in such a way as to not overwrite the information each
> time the page load.  So for example the cookie is read the information is
> valid, the query to the db, the information set to the session.  You might
> wonder why I dont set the userlevel to the cookie, well I dont want someone
> changing the value of a cookie and getting admin access, which reminds me I
> should add that as a check.
> Thats about it.  getCookieInfo() the function inside the checkLogin function
> just looks up the information for the cookie in the db.  I know that someone
> is going to say something really simple that I am going to slap my forehead
> over, I would like to thank that person before hand.
>
> function checkLogin () {
>  /* Check if user has been remembered */
>  if (isset($_COOKIE['cookname']) && isset($_COOKIE['cookid'])) {
>  if (!isset($_SESSION['name']) && !isset($_SESSION['id']) &&
> !isset($_SESSION['level']) && !isset($_SESSION['password'])) {
>   $cookieInfo=getCookieInfo($_COOKIE['cookname'], $_COOKIE['cookid']);
>   if ($cookieInfo==0) {
>return 0;
>   }
>   if ($cookieInfo==1) {
>setcookie("cookname", "", time()-60*60*24*100, "/");
>   setcookie("cookid", "", time()-60*60*24*100, "/");
>return 1;
>   }
>   if ($cookieInfo==2) {
>setcookie("cookname", "", time()-60*60*24*100, "/");
>   setcookie("cookid", "", time()-60*60*24*100, "/");
>return 2;
>   }
>  }
>  }
>
>  if (isset($_SESSION['name']) && isset($_SESSION['id']) &&
> isset($_SESSION['level']) && isset($_SESSION['password'])) {
>  if (loginUser($_SESSION['username'], $_SESSION['password'],'') != 1) {
>   unset($_SESSION['name']);
>   unset($_SESSION['id']);
>   unset($_SESSION['level']);
>   unset($_SESSION['password']);
>   $_SESSION = array(); // reset session array
>  session_destroy();   // destroy session.
>   // incorrect information, user not logged in
>   return 0;
>  }
>  // information valid, user okay
>  return 1;
>  } else {
>  // user not logged in
>  return 2;
>  }
> }
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Re: [SOLVED] [PHP] date from YYYY-MM-DD to current date

2006-03-15 Thread Dan McCullough
Sorry Gmail doesnt always put all the email address on the TO line in a reply.

On 3/15/06, Shaunak Kashyap <[EMAIL PROTECTED]> wrote:
> In the future, please reply to the list. Also, I assume this question
> has been answered and am, therefore, marking it with [SOLVED].
>
> Shaunak Kashyap
>
> Senior Web Developer
> WPT Enterprises, Inc.
> 5700 Wilshire Blvd., Suite 350
> Los Angeles, CA 90036
>
> Direct: 323.330.9870
> Main: 323.330.9900
>
> www.worldpokertour.com
>
> Confidentiality Notice:  This e-mail transmission (and/or the
> attachments accompanying) it may contain confidential information
> belonging to the sender which is protected.  The information is intended
> only for the use of the intended recipient.  If you are not the intended
> recipient, you are hereby notified that any disclosure, copying,
> distribution or taking of any action in reliance on the contents of this
> information is prohibited. If you have received this transmission in
> error, please notify the sender by reply e-mail and destroy all copies
> of this transmission.
>
> > -Original Message-
> > From: Dan McCullough [mailto:[EMAIL PROTECTED]
> > Sent: Wednesday, March 15, 2006 10:22 AM
> > To: Shaunak Kashyap
> > Subject: Re: [PHP] date from -MM-DD to current date
> >
> > excellent, I was getting close, was getting hung up on a couple of
> things
> >
> > On 3/15/06, Shaunak Kashyap <[EMAIL PROTECTED]> wrote:
> > > // $pastDateStr = string representation of past date
> > > $pastDateTS = strtotime($pastDateStr);
> > >
> > > For ($currentDateTS = $pastDateTS;
> > >$currentDateTS <= strtotime("now");
> > >$currentDateTS += (60 * 60 * 24)) {
> > >
> > >// use date() and $currentDateTS to format the dates in
> between
> > >
> > > }
> > >
> > > HTH,
> > >
> > > Shaunak Kashyap
> > >
> > > Senior Web Developer
> > > WPT Enterprises, Inc.
> > > 5700 Wilshire Blvd., Suite 350
> > > Los Angeles, CA 90036
> > >
> > > Direct: 323.330.9870
> > > Main: 323.330.9900
> > >
> > > www.worldpokertour.com
> > >
> > > Confidentiality Notice:  This e-mail transmission (and/or the
> > > attachments accompanying) it may contain confidential information
> > > belonging to the sender which is protected.  The information is
> intended
> > > only for the use of the intended recipient.  If you are not the
> intended
> > > recipient, you are hereby notified that any disclosure, copying,
> > > distribution or taking of any action in reliance on the contents of
> this
> > > information is prohibited. If you have received this transmission in
> > > error, please notify the sender by reply e-mail and destroy all
> copies
> > > of this transmission.
> > >
> > >
> > > > -Original Message-
> > > > From: Dan McCullough [mailto:[EMAIL PROTECTED]
> > > > Sent: Wednesday, March 15, 2006 9:58 AM
> > > > To: php-general@lists.php.net
> > > > Subject: [PHP] date from -MM-DD to current date
> > > >
> > > > I need to loop from a date in the past to current date getting all
> > > > dates in between.  Anyone have an idea on how to do that?
> > > >
> > > > --
> > > > PHP General Mailing List (http://www.php.net/)
> > > > To unsubscribe, visit: http://www.php.net/unsub.php
> > >
> > >
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] date from YYYY-MM-DD to current date

2006-03-15 Thread Dan McCullough
I need to loop from a date in the past to current date getting all
dates in between.  Anyone have an idea on how to do that?

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] What's a Blog?

2006-02-14 Thread Dan McCullough
Or code and give back to the project

On 2/14/06, Duncan Hill <[EMAIL PROTECTED]> wrote:
> On Tuesday 14 February 2006 16:18, Kim Christensen wrote:
> > On 2/14/06, Duncan Hill <[EMAIL PROTECTED]> wrote:
> > > WordPress is free, has a neat WYSIWYG editor in version 2, and has a good
> > > support community.  5 minutes to install vs an hour to code a basic
> > > interface - I'd take the 5 minutes :p
> >
> > That being said, get lost from the PHP user list! :-)
>
> No point continually re-inventing the wheel :)  There are PHP (and other
> language) packages that potentially solve the problem faster than coding it.
> Leaving the spare time to code uber-nifty things instead!
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Blogger post failed?

2006-02-14 Thread Dan McCullough
Got one yesterday, was very odd.

On 2/14/06, Kevin Kinsey <[EMAIL PROTECTED]> wrote:
> Jay Blanchard wrote:
>
> > Is anyone else getting these messages?
>
>
> Yes.
>
> > Very annoying.
>
>
> Yes.
>
> Barry wrote:
>
> ] Sometimes.
>
> ] Proably the server is reaching its limits :P
>
>
> Seems doubtful; if I read the headers correctly,
> this list is managed by "ezmlm", which means it's
> running on a qmail server, and probably on FreeBSD
> or Linux.  Not that you couldn't overload such a
> machine/operating system, but it's not real likely.
>
> "Blogger post failed" seems to indicate that someone
> is attempting to pipe their subscription to their
> blog/website/whatever; when this fails, their MTA
> doesn't know who else to notify but the "sender",
> e.g. "php-general@lists.php.net", and we all get
> a nice error message to sift.
>
> I suppose it's just like any community; if somebody
> farts on the subway, we all get to share the result
>
> #include 
>
> Kevin Kinsey
>
> --
> My own business always bores me to death; I prefer other people's.
> -- Oscar Wilde
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] What's a Blog?

2006-02-13 Thread Dan McCullough
Wordpress is free and easy to setup.

On 2/13/06, Sam Smith <[EMAIL PROTECTED]> wrote:
>
>
> I have a client who wants to blog or he wants a blog on his website. I don't
> know anything about these blogs except it's sort of a fad I think.
>
> Isn't a blog just a simple web form with a big textarea on the blogger's
> side writing to a database and then the data is displayed in chronological
> order on the readers side of a website? I could create that in under an
> hour.
>
> What don't I know? I searched up some scripts, some were free some were
> $500!
>
> Somebody like to point me at a good script that would enlighten me?
>
> Thanks
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Recompile PHP on pre-installed system

2006-02-08 Thread Dan McCullough
you can use php-odbc make sure you have unixODBC or like install on
the system, once you do that its a piece of cake, been doing that here
for a few months.

On 2/8/06, Justin Cook <[EMAIL PROTECTED]> wrote:
> Yes, we are using RHE 4 with a support contract. I need to get db2 support 
> compiled in so we can access our AS400 using ODBC.  _
>
> From: Rory Browne [mailto:[EMAIL PROTECTED]
> To: Marcus Bointon [mailto:[EMAIL PROTECTED]
> Cc: Justin Cook [mailto:[EMAIL PROTECTED], PHP General [mailto:[EMAIL 
> PROTECTED]
> Sent: Wed, 08 Feb 2006 12:45:16 -0600
> Subject: Re: [PHP] Recompile PHP on pre-installed system
>
> If you're using a Redhat Enterprise version with a support contract  then I 
> personally don't think you should attempt to run a non-redhat  php binary.
>
>  Instead find out how redhat make their php-mysql or php-ldap or  
> php-{some_other_php_module} rpm, Make an RPM, and install it like you  would 
> any other RPM.
>
>  Better still would be to upgrade to Debian( they have more php modules  I 
> believe than RH), but that would require much more downtime than an  apache 
> restart.
>
>  What module do you need?
>
>
> On 2/7/06, Marcus Bointon <[EMAIL PROTECTED]> wrote:  On 7 Feb 2006, at 
> 11:13, Jochem Maas wrote:
>
> > in theory your done, in practice something might bite you in the
> > ass ...
> > oh and then there is the issue of making sure that the redhat
> > package manager really
> > won't overwrite your handbuilt php install (cannot for the life of
> > me remember what you have
> > to do to make redhat ignore the php install).
>
> This might be of help:   http://www.ae.iitm.ac.in/pipermail/ilugc/2005-
> August/020152.html
>
> You can edit those srpms to include whatever configure line switches
> you need.
>
> I run RHEL4, and my own compile of PHP, set up outside of rpm. You
> only need to worry about rpm getting confused if you use it to
> install any packages that are dependent on php, e.g. squirrelmail.
> Essentially either do ALL of your PHP setup and install through rpm
> or none of it. I'm quite happy handling PHP myself, and conflicts are
> rare as php is rarely a dependency for apps installed through rpm.
>
> Marcus
> --
> Marcus Bointon
> Synchromedia Limited: Putting you in the picture
> [EMAIL PROTECTED]   | http://www.synchromedia.co.uk
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit:   http://www.php.net/unsub.php
>
>
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] load testing tools

2005-12-27 Thread Dan McCullough
Anyone have any opinions or suggestions on cheap/free load testing
tools for dynamic sites?

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Re: asianwhiteskin beauty product

2005-12-20 Thread Dan McCullough
Maybe this is a disk space product, increases disk space on all types of drives.

On 12/20/05, Michelle Konzack <[EMAIL PROTECTED]> wrote:
> Am 2005-12-15 15:00:41, schrieb Dan McCullough:
> > Is this some sort of new Zend product? :)
>
> Can this implemented?  I have only 75A and do
> not like become patched with plastic.  ;-P
>
> If men can increase 3-4 inches...
>...why not me 3-4 cups?  =8
> Greetings
> Michelle
>
> --
> Linux-User #280138 with the Linux Counter, http://counter.li.org/
> # Debian GNU/Linux Consultant #
> Michelle Konzack   Apt. 917  ICQ #328449886
>   50, rue de Soultz MSM LinuxMichi
> 0033/3/8845235667100 Strasbourg/France   IRC #Debian (irc.icq.com)
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] asianwhiteskin beauty product

2005-12-15 Thread Dan McCullough
Is this some sort of new Zend product? :)

On 12/15/05, Michelle Konzack <[EMAIL PROTECTED]> wrote:
> Am 2005-12-13 10:09:41, schrieb Raz:
> > Can I have some breast enlarger please?
>
> :-)
>
> Me too...
>
> Greetings
> Michelle
>
> --
> Linux-User #280138 with the Linux Counter, http://counter.li.org/
> Michelle Konzack   Apt. 917  ICQ #328449886
>   50, rue de Soultz MSM LinuxMichi
> 0033/3/8845235667100 Strasbourg/France   IRC #Debian (irc.icq.com)
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] PHP/MySql noob falls at first hurdle

2005-12-09 Thread Dan McCullough
I would hate to see a time clock that tabulated how many hours I
wasted with typos and stupid things like that.

On 12/9/05, Rory McKinley <[EMAIL PROTECTED]> wrote:
> Paul Jinks wrote:
> > Rory McKinley wrote:
> >
> >> Paul Jinks wrote:
> >> 
> >>
> >>> >>>while($ouput_row = mysql_fetch_array($result)) {
> >>>?>
> >>>
> >>
> >>
> >> 
> >>
> >>
> >> Paul - is this the actual code that you are using? - because you have a
> >> typo in your while statement - $ouput_row instead of $output_row - means
> >> that when you try and echo $output_row it doesn't exist!
> >>
> >> Rory
> >>
> >>
> > Oh no.  I can't believe it. That was it. An idiotic typo.
> 
>
> I wouldn't stress too much - happens to me all the time (sigh) and
> (apparently) it happens to the best of us - but I am not qualified to
> comment on the veracity of that statement :).
>
> For future reference, during testing, you can set your error reporting
> levels ( i think) in php.ini to output a notice regarding a variable
> that does not exist - would have helped you spot the error! I normally
> use the Zend debugger which does quite a good job of telling me that I
> am an idiot :)
>
> Rory
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Testing on the local server

2005-11-18 Thread Dan McCullough
Coincidence 

On 11/18/05, Jay Blanchard <[EMAIL PROTECTED]> wrote:
> [snip]
> I use Dreamweaver and I try to test the files on the local host, but the
> page doesn't even show up. This maybe a stupid question..but to test on a
> local server, would I just need to download PHP?
> [/snip]
>
> Deja Vu?
>
> Did you install the package on your server that I recommended?
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] testing on a local server

2005-11-18 Thread Dan McCullough
Well Jay was showing you where you could pick up everything you
needed.  On Windows XP the IIS server is not installed by default you
have to select it as a component to install, so I'm not sure if you
would have IIS installed either.  If you want a simple and quick
solution go to the link that Jay sent and download that installer
you'll get Apache/PHP/MySQL and some other tools for development.

Good luck

On 11/18/05, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
> i'm not sure if my messages are getting through...but i'm trying to download 
> the
> PHP installer - where it asks which type of http server i want to configure,
> how do i find out what i have? it would be one of the microsoft servers, but i
> have no idea which...
>
>
> Quoting [EMAIL PROTECTED]:
>
> > i am new to PHP and web programming/management in general...
> >
> > Using Dreamweaver I am trying to preview .php files on the local server, but
> > the
> > page won't show up in a web browser. This is probably a stupid question, but
> > does that just mean I need to install PHP on my computer?
> >
> > 
> > This message was sent using IMP, the Internet Messaging Program.
> >
> > --
> > PHP General Mailing List (http://www.php.net/)
> > To unsubscribe, visit: http://www.php.net/unsub.php
> >
> >
>
>
>
>
> 
> This message was sent using IMP, the Internet Messaging Program.
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: Re[2]: [PHP] Cookies

2005-11-17 Thread Dan McCullough
:) why of course

On 11/17/05, Richard Davey <[EMAIL PROTECTED]> wrote:
> Hi Dan,
>
> Thursday, November 17, 2005, 3:56:43 PM, you wrote:
>
> > You can check on every page load, but I'm sure thats over kill for
> > most public facing sites to catch some Yahoos who have too much time
> > on their hands.
>
> Is that a new technical term for 'hacker' ? :)
>
> Cheers,
>
> Rich
> --
> Zend Certified Engineer
> PHP Development Services
> http://www.corephp.co.uk
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Cookies

2005-11-17 Thread Dan McCullough
You can check on every page load, but I'm sure thats over kill for
most public facing sites to catch some Yahoos who have too much time
on their hands.

On 11/17/05, Richard Davey <[EMAIL PROTECTED]> wrote:
> Hi Ben,
>
> Thursday, November 17, 2005, 3:26:04 PM, you wrote:
>
> > Is there a way to test if a user has cookies turned on or not so
> > that I can use cookies if the user allows them and use the URL if
> > the user does not allow them?
>
> Set one? :)
>
> Then check if it exists or not.
>
> This of course will not catch those sneaky buggers who disable cookies
> part way through your site just to see what effect it will have.
>
> Cheers,
>
> Rich
> --
> Zend Certified Engineer
> PHP Development Services
> http://www.corephp.co.uk
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Cookies

2005-11-17 Thread Dan McCullough
Tried and true is to set a cookie and then attempt to read it, if you
cant read it then cookies are not on.

On 11/17/05, Ben Miller <[EMAIL PROTECTED]> wrote:
> Is there a way to test if a user has cookies turned on or not so that I can
> use cookies if the user allows them and use the URL if the user does not
> allow them?
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Developement Environment for PHP?

2005-11-16 Thread Dan McCullough
Zend Studio
PHPEclipse
LAMP + Notepad :)

On 11/16/05, Tom Cruickshank <[EMAIL PROTECTED]> wrote:
> Hello,
> I'm not sure if this has been asked before or not (probably has) but I
> can't seem to find it. I'm looking for a Development Environment for PHP
> other then vi. What I'm looking for is an environment which has powerful
> debugging techniques and resources. Preferably using a Unix based platform
> (that's what I'm developing on).
>
> Would anyone have any suggestions?
>
> Tom
>
>
>
> --
> No virus found in this outgoing message.
> Checked by AVG Free Edition.
> Version: 7.1.362 / Virus Database: 267.13.3/173 - Release Date: 11/16/2005
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Error Messages, Windows, and Tequila

2005-11-16 Thread Dan McCullough
Also check to make sure that its the right php.ini file, I have had a
problem in the past when the installer has put the php.ini file in the
WINDOWS directory and there is an existing one in the PHP directory as
well.  I would check phpinfo and see where the php.ini file is
located.

On 11/16/05, Richard Davey <[EMAIL PROTECTED]> wrote:
> Hi Jay,
>
> Wednesday, November 16, 2005, 4:36:25 PM, you wrote:
>
> > Does anyone know (I have error reporting set so high it would make
> > your head swim) why errors wouldn't be output to a browser window
> > when they occur? For instance, I typed the following;
>
> Are you 100% Tequila-worm sure you've got all the relevant ini flags
> set? (display errors, E_ALL, yadda yadda) and that PHP on your lovely
> Windows box is actually *using* that ini file and not the mystic
> built-in one?
>
> Tis the only reason I can think of that would halt it dead, because as
> shocking as this may sound - PHP on Windows *can* actually display
> errors ;)
>
> Cheers,
>
> Rich
> --
> Zend Certified Engineer
> PHP Development Services
> http://www.corephp.co.uk
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Cannot find bison and Flex even when those are installed

2005-11-11 Thread Dan McCullough
You might have to change the configure option from
with-bison=/usr/local/bison to with-bison=/usr or even with-bison=

Happens to me alot.

This would also be a better email for the PHP INSTALL list

On 11/11/05, Jurgen <[EMAIL PROTECTED]> wrote:
> Dear group
>
> I tried to install php 4.3.11 on Linux Suse 6.4. I've installed bison and
> flex in /usr/local/
>
> When I run ./configure in my php-dir he tells me he can't find bison and
> flex.
>
> How can I solve this matter
>
> Jurgen Campforts
> Lichtaartsebaan 58
> 2460 Kasterlee
> Tel: 0496/60.25.75
> http://www.wandelmee.be
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] T_PAAMAYIM_NEKUDOTAYIM

2005-11-10 Thread Dan McCullough
LOL coding mirrors life.

On 11/10/05, Jay Blanchard <[EMAIL PROTECTED]> wrote:
> [snip]
> > > >
> > > > It means that you have two colons not being used correctly
> > >
> > > its a good thing this mailinglist is not about the practice
> > > of medicine ;-)
> > >
> > If it was, I suppose you would recommend 'colonic irrigation' then? Twice,
> > perhaps?
> >
> That could get messy
> [/snip]
>
> Well, you see what it did to his code already.
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] T_PAAMAYIM_NEKUDOTAYIM

2005-11-10 Thread Dan McCullough
That could get messy

On 11/10/05, George Pitcher <[EMAIL PROTECTED]> wrote:
>
> > >
> > > It means that you have two colons not being used correctly
> >
> > its a good thing this mailinglist is not about the practice
> > of medicine ;-)
> >
> If it was, I suppose you would recommend 'colonic irrigation' then? Twice,
> perhaps?
>
> George
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] T_PAAMAYIM_NEKUDOTAYIM

2005-11-09 Thread Dan McCullough
t_paamayim_nekudotayim is Hebrew for term twice colon
I believe that its saying that you need to use the :: operator.

On 11/9/05, Unknown Unknown <[EMAIL PROTECTED]> wrote:
> I was working with objects, and suddenly i got this error:
> *Parse error*: syntax error, unexpected T_PAAMAYIM_NEKUDOTAYIM in *
> D:\Apache\Apache(re)\Apache2\htdocs\Include.php* on line *11*
> is this like a bug in PHP or is it a valid error?
> thanks in advance
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Unable to send variables to MySQL table

2005-11-09 Thread Dan McCullough
What is the structure of that table?

On 11/9/05, Stewart Priest <[EMAIL PROTECTED]> wrote:
> 
> print $add_to_db;
> 
>
> Thanks for all your replies! I didn't expect to get one so quick, so thanks!
>
> After I did the above, I pasted the output into MySQL. Guess what? It didn't
> work!
>
> I was only sending values for $item1_desc and $item1_cost. Because I was not
> sending values for the other columns, I was getting an error message saying
> the data was truncated for the empty variables.
>
> Now I need to figure out how to send empty values... would NULL do the job?
>
> Thanks again!
> Stewart
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Unable to send variables to MySQL table

2005-11-09 Thread Dan McCullough
print $add_to_db;

should print out the entire insert line and you can just double check
that your values are full, otherwise like Jay said I would check and
make sure the user you have in your connect string can write to the
db.

On 11/9/05, Stewart Priest <[EMAIL PROTECTED]> wrote:
> Hi folks... a bit of a newbie question I'm afraid...
>
> I've written this script shown below. It gets its variables from a form, and 
> then it (supposedly!) writes these values into a MySQL table ('invoices').
>
> The script executes with no errors, but when I check the table, the table is 
> still empty. I can manually insert the data directly into the table, and when 
> I echo the variables in the script, the values are displayed whe I run it, 
> but for reasons unknown, the values are not written to the table.
>
> Any ideas? The code is below.
>
> Many thanks.
> Stewart
>
> 
> // this opens the connection to the db
> include 'library/opendb.php';
>
> // this adds detals to the invoice table
> $item1_desc = $_REQUEST['item1_desc'];
> $item2_desc = $_REQUEST['item2_desc'];
> $item3_desc = $_REQUEST['item3_desc'];
> $item4_desc = $_REQUEST['item4_desc'];
> $item1_cost = $_REQUEST['item1_cost'];
> $item2_cost = $_REQUEST['item2_cost'];
> $item3_cost = $_REQUEST['item3_cost'];
> $item4_cost = $_REQUEST['item4_cost'];
> $delivery_cost = $_REQUEST['delivery_cost'];
>
> $add_to_db = "insert into invoices (item1_desc, item1_cost, item2_desc, 
> item2_cost, item3_desc, item3_cost, item4_desc, item4_cost, delivery_cost) 
> values ('$item1_desc', '$item1_cost', '$item2_desc', '$item2_cost', 
> '$item3_desc', '$item3_cost', '$item4_desc', '$item4_cost', 
> '$delivery_cost')";
> mysql_query($add_to_db);
>
> ?>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] reg ex help

2005-11-04 Thread Dan McCullough
Whos responsible for putting all that information into one field.  LOL

On 11/4/05, conditional motion <[EMAIL PROTECTED]> wrote:
> The name like "Roch Small Sum" and others dont change, they will be in
> there whether there is a value associated with them or not.
>
>
> On 11/4/05, conditional motion <[EMAIL PROTECTED]> wrote:
> > Here is what the field content from the database would look like.  I
> > have removed any sensitive data.
> >
> > str = "Name;Grill Transom (GT302)^% -
> > Sort;Find/Replace^% - Calc;2568.09x^% -
> > Type;Veck^% - PO Number;^% - Previous Order
> > Number;^% - Fabric Whole;Dyna-Dry^% - Fabric
> > Body;^% - Fabric Yoke;^% - Fabric
> > Sleeves;^% - Fabric Panels;^% -
> > ID;32398^%^%^%^%^% -
> > Size;6.0^%^%^%^%^% -
> > Layer;0^%^%^%^%^% -
> > Coords;147^173^400^%^^^%^^^%^^^%^^^%
> > - ID;%32400^%^%%%^%
> > - 
> > Coords;%147^110^400^%^^^%%%^^^%
> > - Back Number
> > Font;%Athletic^Athletic^%
> > - Front Text
> > ID;%%32402^%32403^%^%^%^%^%^%
> > - Roch Small Sum;0^% - Cards Med Extra;0^%
> > - Roch Large Sum;0^% - Silver Small Corp;X^%
> > - Gold Medium Corp;RE^% - Platinum Large
> > Corp;YRE^%";
> >
> > That is one field.
> >
> > On 11/4/05, Pablo Gosse <[EMAIL PROTECTED]> wrote:
> > > [snip]
> > > The problem with that is there are about 40 different listings in the
> > > one field.
> > >
> > > Silver Small Corp;X^%\n#\n
> > > Gold Medium Corp;RE^%\n#\n
> > > Platinum Large Corp;YRE^%\n#\n
> > >
> > > being three of them so maybe this is a bettter way of listing it
> > >
> > > ... Silver Small Corp;X^%\n#\nGold Medium
> > > Corp;RE^%\n#\nPlatinum Large Corp;YRE^%\n#\n
> > > ...[/snip]
> > >
> > > Try this:
> > >
> > > $values = array(); // we'll put the extracted vars here
> > > $str = "This is supposed to be your string";
> > >
> > > $tmpStr = explode("#\n", $str);
> > >
> > > foreach ($tmpStr as $foo) {
> > >if (strlen(trim($foo)) > 0) {
> > >array_push($values, substr($foo, 0, strpos($foo, ';')));
> > >
> > >}
> > > }
> > >
> > > HTH,
> > >
> > > Pablo
> > >
> > > --
> > > PHP General Mailing List (http://www.php.net/)
> > > To unsubscribe, visit: http://www.php.net/unsub.php
> > >
> > >
> >
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] getting rid of bad characters

2005-10-31 Thread Dan McCullough
I having been looking for some snippet to help me with changing MS
Word double, quotes, single quotes and other characters to acceptable
HTML safe characters.  The problem comes about when the people using
the forms paste large articles from Word into the form, I do a normal
check and add slashes but lately they have been getting lazy and using
the special characters from Word.

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] XML-RPC Error:-32300:transport error - could not open socket

2005-10-28 Thread Dan McCullough
It was the version of class-IXR.php, there was a small bug in that
library and the fix had just come out, so it was until I went back and
download some updates that it worked.

On 10/22/05, Richard Lynch <[EMAIL PROTECTED]> wrote:
> On Sat, October 22, 2005 10:19 am, Dan McCullough wrote:
> > I'm having any issue finding out why this is happening and how to fix
> > it.  Is it a permissions problem between php and the server or
> > something else?
> > Help
>
> Go to the command line/shell or even, gak, MS-DOS, and type:
>
> telnet XYZ 32000
>
> XYZ should be an IP address like 192.168.1.1 or a domain name.
>
> Either the server responds, or it's not working and PHP can't fix it.
>
> --
> Like Music?
> http://l-i-e.com/artists.htm
>
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] XML-RPC Error:-32300:transport error - could not open socket

2005-10-22 Thread Dan McCullough
Tried Google and the guy who created the snippet they had no helpful
information about the error.

On 10/22/05, Torgny Bjers <[EMAIL PROTECTED]> wrote:
> Dan McCullough wrote:
>
> >I'm having any issue finding out why this is happening and how to fix
> >it.  Is it a permissions problem between php and the server or
> >something else?
> >Help
> >
>
> Without looking up this specific error code thoroughly through Google or
> elsewhere, I would have to ask you to submit the code excerpt that
> generates this error. If it is a permission error it could be because
> you are trying to listen to a system reserved port in the 0-1024 range,
> or it could be that the URL that you are trying to open is actually
> invalid. For instance, if trying to connect to http:// you could have
> forgotten a slash, or used backslashes, or any other common mistake.
> Please submit more information the next time, and use Google, it
> actually finds information for you. :)
>
> Regards,
> Torgny
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] XML-RPC Error:-32300:transport error - could not open socket

2005-10-22 Thread Dan McCullough
I'm having any issue finding out why this is happening and how to fix
it.  Is it a permissions problem between php and the server or
something else?
Help

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] automatic login..

2005-10-14 Thread Dan McCullough
some logic and information.
set the cookie to expire after 120 days or so, or never.  you will
have to set a cookie with the username and password, preferably a md5
encrypted password.  also remember to have the logout function to
remember those cookies.

On 10/14/05, ganu <[EMAIL PROTECTED]> wrote:
> hi,
>
> I created one site , and i implemented the concept of mypage same like as 
> google or yahoo
> or excite.com,
>
> now my problem is i just want to put a line{href} in my mypge as set as home 
> page so when
> the user will click on that , so it will set this page as default page..
>
> And next time he/she will come then no need of login the mypage will open 
> automatically,
> I think i hv to track the cookies and store the ip into
> the table or something like that,
>
> plz any body can help me and gv some hint , for how it is possible...
>
> any logic or ideas,
>
> thnx..
> Open Source Ki Jai..
> ~ ganu maharaj..
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Help with logic :(

2005-10-14 Thread Dan McCullough
Not a problem, good to see.

On 10/14/05, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
> NEVERMIND.
>
> Solved it.
>
> Thanks!!!
>
> A
>
> > Hi all,
> >
> > Just wondering how one would do multiple rows?
> >
> > Instead of me me copying and pasting the same row of code 15 times
> > (multiple data entry form), I just loop until it counts 15?
> >
> > Loops are not a strong point for me at all :(
> >
> > Thanks in advance!!!
> >
> > Aaron
> >
> > --
> > PHP General Mailing List (http://www.php.net/)
> > To unsubscribe, visit: http://www.php.net/unsub.php
> >
> >
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] test

2005-10-14 Thread Dan McCullough
did it work ;)

On 10/14/05, Alan Lord <[EMAIL PROTECTED]> wrote:
> please ignore
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Mark Email as Urgent

2005-10-13 Thread Dan McCullough
add a header in the mail function between 1 - 5, 1 being the highest
$headers .= "X-Priority: 1\n";

On 10/13/05, Nathaniel Hall <[EMAIL PROTECTED]> wrote:
> I have a PHP script that automatically sends an e-mail when accessed.  Is 
> there any way to mark the e-mail that is sent
> as urgent or flagged?
>
> Any help is appreciated.
>
> --
> Nathaniel Hall, GSEC
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] onChange js running a php function

2005-10-11 Thread Dan McCullough
Its been awhile since I tried this so I was wondering if anyone had
any luck with this.

I need to get a list of tables from a database, which means I have to
run a function, I would like to have an onChange event run when I
change my selection in a select menu, that would send the value for
the select menu to a php function.
can that be done?

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Obsession with BC

2005-10-11 Thread Dan McCullough
The real problem is that it generates customer service and support
calls to the hosting company, which they dont like to have to deal
with, because in the end it will be a coding issue and most of the
people out there wont realize it and get mad and leave.

On 10/11/05, Kilbride, James <[EMAIL PROTECTED]> wrote:
> 4 to 5 does break a lot of code. On the other hand I agree it's a cop
> out. On the final hand, if you pass the pages off from apache to a php
> exe or module.. How does Apache know which one to pass it to? Php4 or
> Php5? If I have both php4 and php5 code in a page should i run both
> sections or only the sections listed for php5(if it's on php5)? If I
> only run one then I am maintaining two code branches in the same files.
> Seems like a bad idea to me. I don't really see how that idea would work
> well. And I do think it seems like a cop out that they can't provide
> php5 somehow.
>
> James Kilbride
>
> > -Original Message-
> > From: Dan McCullough [mailto:[EMAIL PROTECTED]
> > Sent: Tuesday, October 11, 2005 2:04 PM
> > To: php-general@lists.php.net
> > Subject: Re: [PHP] Obsession with BC
> >
> > None of my code breaks from 4 to 5, I also run a small
> > hosting company and I upgrade when I see improvements to the
> > software that would warrent an upgrade.  MySQL 4.1.12, Apache
> > 2, PHP5.  I also think its a cop out by those who dont have
> > alot of time to upgrade their 30+ servers.  Another stall or
> > cop-out would be were currently testing
> > php5 and will have an evaluation in a few weeks *cough* months.
> >
> > On 10/11/05, Richard Davey <[EMAIL PROTECTED]> wrote:
> > > Hi,
> > >
> > > Tuesday, October 11, 2005, 5:41:53 PM, you wrote:
> > >
> > > > Recently, I asked my hosting provider when they are going
> > to switch
> > > > to PHP5. They replied that it will not happen any time
> > soon, since
> > > > they will install PHP5 only on new servers. Their reasoning was
> > > > simple: PHP5 will inevitably break some old scripts, and
> > it's just
> > > > not worh all the trouble. Such attitude is common, and it totally
> > > > makes sence from a business perspective.
> > >
> > > It does? I wouldn't waste my money with a host that was unable to
> > > provide PHP 5 support, at least in some way. I think the "it will
> > > break lots of scripts" is a cop-out. There are various ways
> > to allow
> > > both on one server. Assuming they're technically proficient
> > enough of
> > > course.
> > >
> > > Cheers,
> > >
> > > Rich
> > > --
> > > Zend Certified Engineer
> > > http://www.launchcode.co.uk
> > >
> > > --
> > > PHP General Mailing List (http://www.php.net/) To
> > unsubscribe, visit:
> > > http://www.php.net/unsub.php
> > >
> > >
> >
> > --
> > PHP General Mailing List (http://www.php.net/) To
> > unsubscribe, visit: http://www.php.net/unsub.php
> >
> >
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Obsession with BC

2005-10-11 Thread Dan McCullough
None of my code breaks from 4 to 5, I also run a small hosting company
and I upgrade when I see improvements to the software that would
warrent an upgrade.  MySQL 4.1.12, Apache 2, PHP5.  I also think its a
cop out by those who dont have alot of time to upgrade their 30+
servers.  Another stall or cop-out would be were currently testing
php5 and will have an evaluation in a few weeks *cough* months.

On 10/11/05, Richard Davey <[EMAIL PROTECTED]> wrote:
> Hi,
>
> Tuesday, October 11, 2005, 5:41:53 PM, you wrote:
>
> > Recently, I asked my hosting provider when they are going to switch
> > to PHP5. They replied that it will not happen any time soon, since
> > they will install PHP5 only on new servers. Their reasoning was
> > simple: PHP5 will inevitably break some old scripts, and it's just
> > not worh all the trouble. Such attitude is common, and it totally
> > makes sence from a business perspective.
>
> It does? I wouldn't waste my money with a host that was unable to
> provide PHP 5 support, at least in some way. I think the "it will
> break lots of scripts" is a cop-out. There are various ways to allow
> both on one server. Assuming they're technically proficient enough of
> course.
>
> Cheers,
>
> Rich
> --
> Zend Certified Engineer
> http://www.launchcode.co.uk
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Help with logic :(

2005-10-11 Thread Dan McCullough
$result = mysql_query($query) or die(mysql_error());

On 10/11/05, Silvio Porcellana <[EMAIL PROTECTED]> wrote:
> [EMAIL PROTECTED] wrote:
> >  >
> >   include ("../utils.inc");
> >
> >   $date = date("U");
> >   $dateExpire = $date + 90 * 86400;
> >
> >   $code = "jack";
> >
> >   $query = "INSERT INTO CouponTable VALUES
> > ('','$date','0','$code','preset','$dateExpire','3.75')";
> >
> >   $result = mysql_query($query);
> >
> >   echo mysql_error($result);
> >
> > ?>
> >
> > This SHOULD error out but I'm getting the error instead.
> >
> > It's just a test page to test my logic...
> >
>
> If you read carefully this page:
>
> http://php.net/mysql_error
>
> you will notice that it says that you need to pass to mysql_error *the
> MySQL connection*. Not the resource returned by mysql_query.
>
> HTH, cheers
> Silvio
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Help with logic :(

2005-10-11 Thread Dan McCullough
got some code so we can see?

On 10/11/05, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
> Thanks everyone. Makes sense. Now I got another issue.
>
> When I try to see if an error exists I get this:
>
> Warning: mysql_error(): supplied argument is not a valid MySQL-Link
> resource in /home//public_html/Store/test.php on line 14
>
> Is there a setting somewhere that I need to set to make sure this is
> available?
>
> Thanks and sorry is these are dumb-ass questions :)
>
> Aaron
>
>
> > Yes I believe that is what Richard was saying about "Trap the INSERT
> > error", you should get an error back from the database about having a
> > problem with the insert instead of showing that error you will want to
> > add some logic that when that error occurs you simply generate another
> > number.
> >
> > On 10/11/05, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
> >> Hi Richard,
> >>
> >> Ok... I do already have a Unique index on the column but this process is
> >> something that I cannot echo out the error code to the user. The code is
> >> generated on the fly when an order an is placed so you can see... I
> >> can't
> >> echo out the error to the customer.
> >>
> >> Can I do an if statement IF an error is returned to try generatre
> >> another
> >> randon code and keep going until one is available? I can do this all
> >> intenrally without the customer knowing/seeing anything?
> >>
> >> Hope I am making some sense. Not trying to confuse the issue.
> >>
> >> Thanks. Appreciate your thoughts.
> >>
> >> Aaron
> >>
> >> > On Mon, October 10, 2005 3:24 pm, Dan McCullough wrote:
> >> >> create a function to check if the rndnumber=couponcode row count = 0
> >> >> if not then redo rndnumber if it does = 0 then insert rndnumber
> >> >
> >> > N!
> >> >
> >> > You are creating a RACE CONDITION in which ONE user might generate a
> >> > 'valid' code, and ANOTHER user might generate a 'valid' code AT THE
> >> > SAME TIME, and then they BOTH get the same coupon code.
> >> >
> >> > The probability of this is very very very low, but still NOT zero.
> >> >
> >> > And it's the kind of thing that won't show up in testing, but sure as
> >> > God made little green apples, it WILL happen at the worst possible
> >> > time after you "go live"
> >> >
> >> > The database engine has a *TON* of code in it to avoid this kind of
> >> > Bad Thing happening.
> >> >
> >> > Use it.
> >> >
> >> > create a UNIQUE INDEX on the column that needs to be unique.
> >> >
> >> > Trap the INSERT error.
> >> >
> >> > --
> >> > Like Music?
> >> > http://l-i-e.com/artists.htm
> >> >
> >> > --
> >> > PHP General Mailing List (http://www.php.net/)
> >> > To unsubscribe, visit: http://www.php.net/unsub.php
> >> >
> >> >
> >>
> >>
> >
> > --
> > PHP General Mailing List (http://www.php.net/)
> > To unsubscribe, visit: http://www.php.net/unsub.php
> >
> >
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Help with logic :(

2005-10-11 Thread Dan McCullough
Yes I believe that is what Richard was saying about "Trap the INSERT
error", you should get an error back from the database about having a
problem with the insert instead of showing that error you will want to
add some logic that when that error occurs you simply generate another
number.

On 10/11/05, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
> Hi Richard,
>
> Ok... I do already have a Unique index on the column but this process is
> something that I cannot echo out the error code to the user. The code is
> generated on the fly when an order an is placed so you can see... I can't
> echo out the error to the customer.
>
> Can I do an if statement IF an error is returned to try generatre another
> randon code and keep going until one is available? I can do this all
> intenrally without the customer knowing/seeing anything?
>
> Hope I am making some sense. Not trying to confuse the issue.
>
> Thanks. Appreciate your thoughts.
>
> Aaron
>
> > On Mon, October 10, 2005 3:24 pm, Dan McCullough wrote:
> >> create a function to check if the rndnumber=couponcode row count = 0
> >> if not then redo rndnumber if it does = 0 then insert rndnumber
> >
> > N!
> >
> > You are creating a RACE CONDITION in which ONE user might generate a
> > 'valid' code, and ANOTHER user might generate a 'valid' code AT THE
> > SAME TIME, and then they BOTH get the same coupon code.
> >
> > The probability of this is very very very low, but still NOT zero.
> >
> > And it's the kind of thing that won't show up in testing, but sure as
> > God made little green apples, it WILL happen at the worst possible
> > time after you "go live"
> >
> > The database engine has a *TON* of code in it to avoid this kind of
> > Bad Thing happening.
> >
> > Use it.
> >
> > create a UNIQUE INDEX on the column that needs to be unique.
> >
> > Trap the INSERT error.
> >
> > --
> > Like Music?
> > http://l-i-e.com/artists.htm
> >
> > --
> > PHP General Mailing List (http://www.php.net/)
> > To unsubscribe, visit: http://www.php.net/unsub.php
> >
> >
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Help with logic :(

2005-10-10 Thread Dan McCullough
create a function to check if the rndnumber=couponcode row count = 0
if not then redo rndnumber if it does = 0 then insert rndnumber

On 10/10/05, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
> Hey guys,
>
> Having trouble coming up with a solution to this idea I am trying to
> implement.
>
> I have a "Coupon" table.
>
> I am creating radonly generated coupon codes that go into this table. 12
> chars in length - both number and letters - all lowercase.
>
> I figure I need to do the following:
>
> 1) generate the radon coupon code;
>
> 2) Do query against thethe table to pull out all the currently entered codes;
>
> 3) Loop through all codes to see if any match the randomly generated code;
>
> 4) if a match exists, generate code again and keep doing this until we
> have a code that doesn't match;
>
> 5) If a match doesn't exist, insert code into DB and continue with rest of
> my process.
>
>
> What I am unsure of is how to loop through all codes in the DB and match
> against current randomly generated code and if a match exists, keep
> generating new random codes until one doesn't exist.
>
> Any ideas on how to go about this?
>
> Thank you in advance. Seems pretty simple I'm sure. Just confused on the
> logic.
>
> Thanks.
>
> Aaron
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] ODBC and DB2 functions (PDO_ODBC)

2005-09-28 Thread Dan McCullough
Anyone have any experience with DB2 over ODBC or JDBC from PHP on
Linux?  Looking for some idea of what I will need to be able to
connect to a DB2 server on our network.

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] xml question

2004-12-06 Thread Dan McCullough
Question.  I need to get one value out of an xml document.
...

Desserts
...
 
what do I need to do?
 
$xml_parser = xml_parser_create();
xml_parser_set_option($xml_parser, XML_OPTION_CASE_FOLDING, true);
xml_set_element_handler($xml_parser, "", "");
 
something like this?  or not quite?

__
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

[PHP] access database best pratice

2004-10-28 Thread Dan McCullough

I have a client who wants to update their access database that sits on their XP/IIS 
box.  I plan on using PHP/ODBC connection to do this, however I am not up-to-speed on 
pitfalls or best pratices concerning access and odbc over the web or if I should 
suggest a better course of action, since I am more familiar with point to point secure 
frame connections and MQ messaging for trasactional security.



"Theres no such thing as a problem unless the servers are on fire!"


-
Do you Yahoo!?
Yahoo! Mail Address AutoComplete - You start. We finish.

Re: [PHP] Thanks but problem Again! (MySQL & PHP database script PLEASE)

2004-10-22 Thread Dan McCullough
Its been awhile since I did any PHP but I would look at if you need to excape some of 
those double quote or encapsulate your sql in a single quote.

Sugimoto <[EMAIL PROTECTED]> wrote:Thank you for two of you. Im amazed how quick the 
replys were. Very pleased.
When I simply inserted the PHP sentense, it worked.
But as I turned off register_globals,
and changed as Matthew suggested, it looked like this:

Warning: mysql_num_rows(): supplied argument is not a valid MySQL result
resource in c:\apache\htdocs\momatlib\gen_search1.php on line 49
Records Available

Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result
resource in c:\apache\htdocs\momatlib\gen_search1.php on line 52
BTW

When I added this (or die("Bad query: ".mysql_error()); ) in this part
($result = mysql_query...)

Ive got this.

Bad query: You have an error in your SQL syntax near 'and Tit like and Aut
like and Auty like ' at line 4



Oh NO! Whats wrong with the script??

Any mistype or anything else? Or am I just stupid?

Arigato thank you.

Sugimoto

--










ID
Volume
Date
Title
Author
Page
Page
Image


mysql_connect(localhost,root,love);
mysql_select_db(gendai);
if (empty($_GET["go"]) &
empty($_GET["dt"]) &
empty($_GET["ti"]) &
empty($_GET["au"]) &
empty($_GET["ay"])) {
echo 'Please type something';
}
elseif ($_GET["go"] == "%" |
$_GET["dt"] == "%" |
$_GET["ti"] == "%" |
$_GET["au"] == "%" |
$_GET["ay"] == "%") {
echo 'Not Valid';
}
else {
foreach ($_GET as $value) {
if (empty($value)) $value = "%";
}

$result = mysql_query("select * from gen_table
where GO like ".$_GET["go"]."
and ym like ".$_GET["dt"]."
and Tit like ".$_GET["ti"]."
and Aut like ".$_GET["au"]."
and Auty like ".$_GET["ay"]."");

$rows = mysql_num_rows($result);
echo "$rows Records Available
";

while($row = mysql_fetch_array($result)){
?>


?>">
?>">







.pdf">pdf



}

}
?>




--

HTML file here










Search FieldsInput Valuealign="center">tips
ID [input] maxlength= "10">

Volume [input] "10" maxlength= "10">

Date [input] maxlength= "10">

Title [input] maxlength="60">

Author [input] maxlength="60">

Yomi [input] maxlength="60">

Search Another
Way








 [input] 
 [input] 






-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php





"Theres no such thing as a problem unless the servers are on fire!"


-
Do you Yahoo!?
Express yourself with Y! Messenger! Free. Download now.

Re: [PHP] Re: parsing a string

2004-10-20 Thread Dan McCullough
I tried the print_r on $res.  The preg_match does the first set fine.
So I get:
 
Campus
Bob (Williams)
 
the second one starts 
-
Address123 Main St
-
CityOxford
 
 
and so on
[EMAIL PROTECTED] wrote:
preg_match('#([^|]*)[|]+([^|]*)~[\\]+(([^\\]*)~[\\]+)+#Ui', $string, $res);
use print_r on the $res to check for the results (I'm not 100% sure if
they'll come out in $res[2], $res[3], $res[4], etc. or in $res[4][0],
$res[4][1], etc.


> I knew I shouldnt have abreviated the string.
> here is the string sorry I kinda flubbed on the last string
> "LocationCampus~\\n-\nNameBob
> Williams~\\n-\nAddress123 Main
> St~\\n-\n..."
>
> the ... is a very long list.
>
> how does this change the preg_match
>
> "M. Sokolewicz" wrote:
> Not sure what you want exactly, but here's a way using regexps to
> retrieve the strings seperatly:
> $string = 'CampusBob (Williams)~\toms more
> crap)~\blah blah blah)~\';
> preg_match('#([^|]*)[|]+([^|]*)~[\]+([^\]*)~[\]+([^\]*)~[\]+#Ui',
> $string, $res);
> $campus = $res[1];
> $bob = $res[2];
> $crap = $res[3];
> $blah = $res[4];
> ?>
> Now, if you wanted the positions... then something like this would work:
>
> $string = 'CampusBob (Williams)~\toms more
> crap)~\blah blah blah)~\';
> preg_match('#([^|]*)[|]+([^|]*)~[\]+([^\]*)~[\]+([^\]*)~[\]+#Ui',
> $string, $res);
>
> $campus = strpos($string, $res[1]);
> $bob = strpos($string, $res[2]);
> $crap = strpos($string, $res[3]);
> $blah = strpos($string, $res[4]);
> ?>
>
> Dan McCullough wrote:
>> Hey everyone
>>
>> Having a bit of trouble with something.
>>
>> I have a string which has known patterns.
>>
>> $string"CampusBob (Williams)~\toms more
>> crap)~\blah blah blah)~\";
>>
>> What I am looking for is
>>
>> Location which is Campus
>> Location Name which is Bob (Williams)
>>
>> Help?
>>
>>
>>
>> -
>> Do you Yahoo!?
>> vote.yahoo.com - Register online to vote today!
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
>
> 
> "Theres no such thing as a problem unless the servers are on fire!"
>
>
> -
> Do you Yahoo!?
> Yahoo! Mail - Helps protect you from nasty viruses.




"Theres no such thing as a problem unless the servers are on fire!"


-
Do you Yahoo!?
Take Yahoo! Mail with you! Get it on your mobile phone.

Re: [PHP] Re: parsing a string

2004-10-20 Thread Dan McCullough
I knew I shouldnt have abreviated the string.
here is the string sorry I kinda flubbed on the last string
"LocationCampus~\\n-\nNameBob 
Williams~\\n-\nAddress123 Main St~\\n-\n..."
 
the ... is a very long list.
 
how does this change the preg_match

"M. Sokolewicz" <[EMAIL PROTECTED]> wrote:
Not sure what you want exactly, but here's a way using regexps to 
retrieve the strings seperatly:
$string = 'CampusBob (Williams)~\toms more 
crap)~\blah blah blah)~\';
preg_match('#([^|]*)[|]+([^|]*)~[\]+([^\]*)~[\]+([^\]*)~[\]+#Ui', 
$string, $res);
$campus = $res[1];
$bob = $res[2];
$crap = $res[3];
$blah = $res[4];
?>
Now, if you wanted the positions... then something like this would work:

$string = 'CampusBob (Williams)~\toms more 
crap)~\blah blah blah)~\';
preg_match('#([^|]*)[|]+([^|]*)~[\]+([^\]*)~[\]+([^\]*)~[\]+#Ui', 
$string, $res);

$campus = strpos($string, $res[1]);
$bob = strpos($string, $res[2]);
$crap = strpos($string, $res[3]);
$blah = strpos($string, $res[4]);
?>

Dan McCullough wrote:
> Hey everyone
> 
> Having a bit of trouble with something.
> 
> I have a string which has known patterns.
> 
> $string"CampusBob (Williams)~\toms more crap)~\blah blah 
> blah)~\";
> 
> What I am looking for is 
> 
> Location which is Campus
> Location Name which is Bob (Williams)
> 
> Help?
> 
> 
> 
> -
> Do you Yahoo!?
> vote.yahoo.com - Register online to vote today!

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




"Theres no such thing as a problem unless the servers are on fire!"


-
Do you Yahoo!?
Yahoo! Mail - Helps protect you from nasty viruses.

[PHP] url

2004-10-20 Thread Dan McCullough
I have this old script I wrote 2-3 years back.  I gets arguments from the url.  
index.php?area=blah
 
The client moved the code to another server and some odd happened.  Nothing seems to 
be parsing from the URL anymore.
 
The top code is 
 

HTML
 
THis code no longer seems to work and I am racking my brain trying to figure out what.



"Theres no such thing as a problem unless the servers are on fire!"


-
Do you Yahoo!?
vote.yahoo.com - Register online to vote today!

[PHP] parsing a string

2004-10-20 Thread Dan McCullough
Hey everyone
 
Having a bit of trouble with something.
 
I have a string which has known patterns.
 
$string"CampusBob (Williams)~\toms more crap)~\blah blah 
blah)~\";
 
What I am looking for is 
 
Location which is Campus
  Location Name which is Bob (Williams)
 
Help?
 


-
Do you Yahoo!?
vote.yahoo.com - Register online to vote today!

Re: [PHP] multi dimension array

2004-09-13 Thread Dan McCullough
okay I am working with this now.
what I am seeing is that any information that I want to pull is not coming.

$sql = "SELECT dealer.dealerid as ddealerid, dealer.company as company, dealer.name as 
name,
dealer.surname as surname, dealer.email as email, dealer.contactday as contactday, 
orders.orderid
as oorderid FROM dealer LEFT JOIN orders ON dealer.dealerid = orders.dealerid WHERE 
orders.status
= '10' GROUP BY dealer.dealerid";
$result = mysql_query($sql);
$num_rows = mysql_num_rows($result);
echo "table join select statement -> ".$num_rows."\n";
if (!$result) {
die('Invalid query: ' . mysql_error());
}
if ($num_rows!='0') {
//$message ="$num_rows Orders Waiting for the Dealer.\n\n";
//$message 
.="--\n";
while($row = mysql_fetch_array($result)) {
$orderid = $row['orderid'];
$dealerid = $row['ddealerid'];
echo "dealer id -> 
".$dealerid." | ";
$dealerid = 
$row['email'];
echo "dealer email -> 
".$email."\n";
/*$message .="\nOrder 
#: $orderid | Dealer ID: $dealerid | ";
if ($dealerid != NULL && $dealerid != '0') {
$sql2 = "SELECT * from dealer WHERE dealerid='".$dealerid."'";
$result2 = mysql_query($sql2);
if (!$result) {
die('Invalid query: ' . mysql_error());
}
$row2 = mysql_fetch_array($result2);
$name = $row2['name'];
$email = $row2['email'];

$surname = $row2['surname'];

$company = $row2['company'];
$message .="Company: $company | Name: $name $surname | Email: 
$email\n";
}*/
//if ($dealerid != '0' 
|| $dealerid != NULL) {
$message .= 
"$company (DID: $ddealerid) has $number_orders waiting for them.\n";
$message 
.="--\n";
$message .= 
"Contact.  $name $surname at $email or $contactday \n";
$message .= 
"Order #: $oorderid \n";
$message
.="--\n\n\n";
//} else {
//$message 
.="--\n";
//$message .= 
"Order #: $orderid has no dealer information.\n";
//$message
.="--\n\n\n";
//}
}
$message .="\n\n\n";
//$message 
.="--\n";
$datestamp=date("Y-m-d H:i:s");
$message .="Sent on: ".$datestamp."\n";
$title="$num_rows Orders Waiting for the Dealer";
mail($email_address,$title,$message,$headers);
} else {

so I get 

 (DID: ) has  waiting for them.
--
Contact.at  or  
Order #:  
--


--- Greg Donald <[EMAIL PROTECTED]> wrote:

> On Mon, 13 Sep 2004 07:14:31 -0700 (PDT), Dan McCullough
> <[EMAIL PROTECTED]> wrote:
> > here is the code.
> > 
> > $sql = "select * from dealer, order

Re: [PHP] multi dimension array

2004-09-13 Thread Dan McCullough
here is the code.

++
// end headers

//$sql = "SELECT * from orders WHERE status='10' and dealerid >= '1'";
$sql = "select * from dealer, orders where orders.status='10' and orders.dealerid =
dealer.dealerid order by orders.dealerid asc";
$result = mysql_query($sql);
$num_rows = mysql_num_rows($result);
echo "table join select statement -> ".$num_rows."\n";
if (!$result) {
die('Invalid query: ' . mysql_error());
}
if ($num_rows!='0') {
//$message ="$num_rows Orders Waiting for the Dealer.\n\n";
//$message 
.="--\n";
while($row = mysql_fetch_array($result)) {
$orderid = $row['orderid'];
$dealerid = $row['dealerid'];
/*$message .="\nOrder 
#: $orderid | Dealer ID: $dealerid | ";
if ($dealerid != NULL && $dealerid != '0') {
$sql2 = "SELECT * from dealer WHERE dealerid='".$dealerid."'";
$result2 = mysql_query($sql2);
if (!$result) {
die('Invalid query: ' . mysql_error());
}
$row2 = mysql_fetch_array($result2);
$name = $row2['name'];
$email = $row2['email'];

$surname = $row2['surname'];

$company = $row2['company'];
$message .="Company: $company | Name: $name $surname | Email: 
$email\n";
}*/
if ($dealerid != '0' 
|| $dealerid != NULL) {
$message .= 
"$company (DID: $dealerid) has $number_orders waiting for them.\n";
$message 
.="--\n";
$message .= 
"Contact.  $name $surname at $email or $contactday \n";
$message .= 
"Order #: $orderid \n";
$message
.="--\n\n\n";
} else {
$message 
.="--\n";
$message .= 
"Order #: $orderid has no dealer information.\n";
$message
.="--\n\n\n";
}
}
$message .="\n\n\n";
//$message 
.="--\n";
$datestamp=date("Y-m-d H:i:s");
$message .="Sent on: ".$datestamp."\n";
$title="$num_rows Orders Waiting for the Dealer";
mail($email_address,$title,$message,$headers);
} else {
$message ="No Orders Waiting for the Dealer.\n\n";
$message .="Sent on: ".$datestamp."\n";
$title="No Orders Waiting for the Dealer";
//mail($email_address,$title,$message,$headers);
}
?>


+++


now as you can see I have a formatted message that I am try to create.
what I am trying to do with it is this.

Joe's Deli (DID: 123564) has 3 orders waiting for them.
--
Contact.  Joe Shmoe at [EMAIL PROTECTED] or 610.555.5151
Order #: 2013, 2124, 2158
--

any help? thoughts?
--- Greg Donald <[EMAIL PROTECTED]> wrote:

> On Fri, 10 Sep 2004 13:33:37 -0700 (PDT), Dan McCullough
> <[EMAIL PRO

[PHP] multi dimension array

2004-09-10 Thread Dan McCullough
I believe that would be the correct term for what I need.

Here is what I have been trying to do.

I have orders and customers.  Customers are required to do a few things before we can 
process the
order.  Some times they are very slow in doing so.  So I wanted to write a little 
reminder script
to poke us to email/call them.

So I have orders and customers.  I need to go through and list out the orders and then 
I need to
use the customer to grab all the order associated with them, then list out their 
contact
information.  Anythough on how I can group orders by customer, list the customer 
information (from
another table) and then go on to the next order and so the same thing all over again?

=

"Theres no such thing as a problem unless the servers are on fire!"




___
Do you Yahoo!?
Shop for Back-to-School deals on Yahoo! Shopping.
http://shopping.yahoo.com/backtoschool

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] get all except 1

2004-07-20 Thread Dan McCullough
Thanks.  Discovered some old code after writing.  Boy its been awhile.


dan mccullough
sr. engineer
url:  heathermccullough.com
tf:   866.298.3991
w:   603.444.9808

There is no such thing as a problem, unless the servers are on fire.
Sometimes great opportunity comes brilliantly disguised as bad news.

-Original Message-
From: John W. Holmes [mailto:[EMAIL PROTECTED]
Sent: Tuesday, July 20, 2004 9:39 PM
To: [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Subject: Re: [PHP] get all except 1

Dan McCullough wrote:

> Anything wrong with
> SELECT * FROM story WHERE approved = 1 AND newsId != $newsId AND editionId
=
> $eid ORDER BY newsSortOrder ASC

Should be fine if I understand your question correctly. You can use !=
or <>; same result.

--
---John Holmes...

Amazon Wishlist: www.amazon.com/o/registry/3BEXC84AB3A5E/

php|architect: The Magazine for PHP Professionals - www.phparch.com

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] get all except 1

2004-07-20 Thread Dan McCullough
Anything wrong with
SELECT * FROM story WHERE approved = 1 AND newsId != $newsId AND editionId =
$eid ORDER BY newsSortOrder ASC

dan mccullough
sr. engineer
url:  heathermccullough.com
tf:   866.298.3991
w:   603.444.9808

There is no such thing as a problem, unless the servers are on fire.
Sometimes great opportunity comes brilliantly disguised as bad news.

-Original Message-
From: John W. Holmes [mailto:[EMAIL PROTECTED]
Sent: Tuesday, July 20, 2004 9:29 PM
To: [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Subject: Re: [PHP] get all except 1

Dan McCullough wrote:

> Haven't done this in a while, but here is my question.
> I have 4 stories, and you land on the story page where one story is shown
> and on the side there is a listing of the other 3 stories that are active
in
> that edition.
> So what I would like to do in one query is get the three that are not
shown
> on that page.
>
> So can I do something like
>
> $story_sql="SELECT * FROM story WHERE approved = 1 AND editionId = $eid
> EXCEPT nid = $nid";
>
> $nid is the id of the story whos detail page we are on

SELECT * FROM story WHERE approved = 1 AND editionID = $eid AND nid <> $nid

--
---John Holmes...

Amazon Wishlist: www.amazon.com/o/registry/3BEXC84AB3A5E/

php|architect: The Magazine for PHP Professionals - www.phparch.com

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] get all except 1

2004-07-20 Thread Dan McCullough
Haven't done this in a while, but here is my question.
I have 4 stories, and you land on the story page where one story is shown
and on the side there is a listing of the other 3 stories that are active in
that edition.
So what I would like to do in one query is get the three that are not shown
on that page.

So can I do something like

$story_sql="SELECT * FROM story WHERE approved = 1 AND editionId = $eid
EXCEPT nid = $nid";

$nid is the id of the story whos detail page we are on

Am I thinking correctly?

dan mccullough
tf:   866.298.3991
w:   603.444.9808

There is no such thing as a problem, unless the servers are on fire.
Sometimes great opportunity comes brilliantly disguised as bad news.

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] Re: Looking For Easy To Use Shopping Cart

2004-05-14 Thread Dan McCullough
http://tutorialized.com/tutorials/PHP/E-Commerce/tutorial/Roll-Out-Your-Cart
/619

very very simple.  The problem with most e-commerce carts out there is that
they come with more then just the cart piece, they have all the product and
ancillary pages and you have to weed through their design.  That's why I
suggest a tutorial as they usually only have the cart piece.

http://tutorialized.com/tutorials/PHP/E-Commerce/tutorial/Building-an-E-Comm
erce-Site-Part-1-Building-a-Product-Catalog/622
http://tutorialized.com/tutorials/PHP/E-Commerce/tutorial/Building-an-E-Comm
erce-Site-Part-2-Managing-Users-with-Sessions/623
http://tutorialized.com/tutorials/PHP/E-Commerce/tutorial/Building-an-E-Comm
erce-Site-Part-3-Catalogs-and-Shopping-Carts/624

A little more involved.

dan mccullough
sr. engineer
url:  heathermccullough.com
tf:   866.298.3991
w:   603.444.9808

There is no such thing as a problem, unless the servers are on fire.
Sometimes great opportunity comes brilliantly disguised as bad news.

-Original Message-
From: Ryan Schefke [mailto:[EMAIL PROTECTED]
Sent: Friday, May 14, 2004 8:05 PM
To: 'Justin Patrin'; [EMAIL PROTECTED]
Subject: RE: [PHP] Re: Looking For Easy To Use Shopping Cart

I want my customer to be able to select a few options via radio buttons (12
months or 24 months - how many photos in their photo album, etc) that impact
the price.  Then, I want the customer to click a "checkout" link that takes
them directly to a form to input billing address and credit card
information.

Any recommendations/guidance?

I'm calling around and speaking to payment gateways and merchant account
providers but wanted to tap into the open source community to see what's out
there that can fit my needs.

I really don't think this is that complex of a task, or maybe it is?

Thanks,
Ryan

-Original Message-
From: Justin Patrin [mailto:[EMAIL PROTECTED]
Sent: Friday, May 14, 2004 6:57 PM
To: [EMAIL PROTECTED]
Subject: [PHP] Re: Looking For Easy To Use Shopping Cart

Ryan Schefke wrote:

> Can anyone recommend a good open source shopping cart solution? I built an
> application for custom websites, now, I just need to interface to a
shopping
> cart. I'm using mysql. Any suggestions?
>
> ...looking for something easy.
>
> Thanks,
> Ryan
>

Well...

Do you mean that you've created a storefront already and need a cart, or
do you need the whole thing? There really isn't any only cart software,
they all include a storefront.

 From what I've seen, Zen Cart is pretty well featured and is open
source and free.

--
paperCrane 

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] Re: Looking For Easy To Use Shopping Cart

2004-05-14 Thread Dan McCullough
That's very simple.  If you don't mind writing a bit of specific code you
could do it in about an hour, there are many snippets of code for payment
processors that you could use.  Try Hotscripts.com.

dan mccullough
sr. engineer
url:  heathermccullough.com
tf:   866.298.3991
w:   603.444.9808

There is no such thing as a problem, unless the servers are on fire.
Sometimes great opportunity comes brilliantly disguised as bad news.

-Original Message-
From: Ryan Schefke [mailto:[EMAIL PROTECTED]
Sent: Friday, May 14, 2004 8:05 PM
To: 'Justin Patrin'; [EMAIL PROTECTED]
Subject: RE: [PHP] Re: Looking For Easy To Use Shopping Cart

I want my customer to be able to select a few options via radio buttons (12
months or 24 months - how many photos in their photo album, etc) that impact
the price.  Then, I want the customer to click a "checkout" link that takes
them directly to a form to input billing address and credit card
information.

Any recommendations/guidance?

I'm calling around and speaking to payment gateways and merchant account
providers but wanted to tap into the open source community to see what's out
there that can fit my needs.

I really don't think this is that complex of a task, or maybe it is?

Thanks,
Ryan

-Original Message-
From: Justin Patrin [mailto:[EMAIL PROTECTED]
Sent: Friday, May 14, 2004 6:57 PM
To: [EMAIL PROTECTED]
Subject: [PHP] Re: Looking For Easy To Use Shopping Cart

Ryan Schefke wrote:

> Can anyone recommend a good open source shopping cart solution? I built an
> application for custom websites, now, I just need to interface to a
shopping
> cart. I'm using mysql. Any suggestions?
>
> ...looking for something easy.
>
> Thanks,
> Ryan
>

Well...

Do you mean that you've created a storefront already and need a cart, or
do you need the whole thing? There really isn't any only cart software,
they all include a storefront.

 From what I've seen, Zen Cart is pretty well featured and is open
source and free.

--
paperCrane 

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] Re: Looking For Easy To Use Shopping Cart

2004-05-14 Thread Dan McCullough
There are several tutorials that are just the cart, probably some minimal
code typing and fixing for your needs.
MyMarket found on SourceForge is one.  There was one on Monkey Junkies.

FreeTrade is good.

dan mccullough
sr. engineer
url:  heathermccullough.com
tf:   866.298.3991
w:   603.444.9808

There is no such thing as a problem, unless the servers are on fire.
Sometimes great opportunity comes brilliantly disguised as bad news.

-Original Message-
From: Justin Patrin [mailto:[EMAIL PROTECTED]
Sent: Friday, May 14, 2004 6:57 PM
To: [EMAIL PROTECTED]
Subject: [PHP] Re: Looking For Easy To Use Shopping Cart

Ryan Schefke wrote:

> Can anyone recommend a good open source shopping cart solution? I built an
> application for custom websites, now, I just need to interface to a
shopping
> cart. I'm using mysql. Any suggestions?
>
> ...looking for something easy.
>
> Thanks,
> Ryan
>

Well...

Do you mean that you've created a storefront already and need a cart, or
do you need the whole thing? There really isn't any only cart software,
they all include a storefront.

 From what I've seen, Zen Cart is pretty well featured and is open
source and free.

--
paperCrane 

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Doing things in the background

2004-03-02 Thread Dan McCullough


Have a script where I need to submit a form and then while its doing its
magic show a animated gif and then display the results.
Also anyone know a good site for a document in indexing tables in mysql.

dan mccullough
sr. engineer
url:  heathermccullough.com
tf:   866.298.3991
w:   603.444.9808

There is no such thing as a problem, unless the servers are on fire.
Sometimes great opportunity comes brilliantly disguised as bad news.

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] mail list/outbound email

2004-01-31 Thread Dan McCullough
Looking for suggestions/thoughts/comments about mail list/outbound
email/"newsletters".  I just bought some software to help my wife's clients
send outbound email campaigns (opt-in/opt-out) not spam.  There have been
several issues right off the hop.  Can anyone think of components that can
be used with php scripts to handle outbound email like those of responsys
and other big boys?

dan mccullough 
sr. engineer
url:  heathermccullough.com <http://www.heathermccullough.com/>  
tf:   866.298.3991
w:   603.444.9808
 
There is no such thing as a problem, unless the servers are on fire. 
Sometimes great opportunity comes brilliantly disguised as bad news.


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

RE: [PHP] Turck MMcache - still continuing or dead?

2004-01-31 Thread Dan McCullough
I'm jumping in kinda late, and I have been using it on two small production
site, and countless small projects.  While I do not use the full array of
its features, even the base features make it a great product.  Never had any
problems

-Original Message-
From: Binay [mailto:[EMAIL PROTECTED]
Sent: Saturday, January 31, 2004 4:42 AM
To: [EMAIL PROTECTED]; 'Raditha Dissanayake'
Cc: [EMAIL PROTECTED]
Subject: Re: [PHP] Turck MMcache - still continuing or dead?


Thanks alottt

Finally have decided to go with MMcache only.

Thanks all for clearing my doubts  once again

Binay
- Original Message -
From: "Adrian Teasdale" <[EMAIL PROTECTED]>
To: "'Binay'" <[EMAIL PROTECTED]>; "'Raditha Dissanayake'"
<[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Saturday, January 31, 2004 2:20 PM
Subject: RE: [PHP] Turck MMcache - still continuing or dead?


>
> > Hi Adrian
> >
> > I looked at the discussion goin on located at sourceforge.
> > But then i m still not able to make up my mind whether to use
> > it or not in my production server. What do u suggest? Is
> > there any problem with the current version of MMcache? Please
> > suggest me.
> >
> > Thanks
> > Binay
>
> As far as I can tell there are no problems using it (at the moment) on a
> production server. We use it on ours with great benefits. The issue is
> whether the project continues and the best way to ensure it does, is
> ultimately to get involved - this is an open source project after all!
> :)
>
> Ade

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] write failed

2003-12-07 Thread Dan McCullough
Just wanted to see if this was correct.  To me this is saying that /tmp
cannot be written to as there is no space left on device.

Warning: Unknown(): write failed: No space left on device (28) in Unknown on
line 0

Warning: Unknown(): Failed to write session data (files). Please verify that
the current setting of session.save_path is correct (/tmp) in Unknown on
line 0


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] RE: dhtml/css/javascript help

2003-12-01 Thread Dan McCullough
This is a bit offtopic.  I need someone who is good at
javascriptt/dhtml/css to help me with a piece of a project, I'm at the end
of
my rope and hoping I dont slip.

I wont go into detail here but you can contact me at
[EMAIL PROTECTED]

The project is a small menu project with categories and subcategories.
Serious inquires only.  Ive had enough of people wasting my time.

thanks

dan




-
This mail sent through IMP: http://horde.org/imp/

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] onClick

2003-11-18 Thread Dan McCullough
I want an event to get triggered when using onClick, but the event will be
MySQL delete/update/insert so how would I go about doing that?

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

  1   2   >