php-general Digest 23 Oct 2012 20:48:42 -0000 Issue 8019

Topics (messages 319555 through 319568):

Re: Recommendation request: Use Magento or build my own eCommerce?
        319555 by: Marc Guay
        319556 by: Mark
        319557 by: Marc Guay
        319558 by: Mark

Re: Missing email
        319559 by: Gerardo Benitez
        319561 by: Karl DeSaulniers

Re: Wrong time being displayed by PHP!
        319560 by: Richard S. Crawford

PDO
        319562 by: Silvio Siefke
        319563 by: Nathan Nobbe
        319564 by: Ashley Sheridan
        319565 by: Adam Richardson
        319566 by: Silvio Siefke
        319567 by: Lester Caine

cron job problem
        319568 by: Jim Giner

Administrivia:

To subscribe to the digest, e-mail:
        php-general-digest-subscr...@lists.php.net

To unsubscribe from the digest, e-mail:
        php-general-digest-unsubscr...@lists.php.net

To post to the list, e-mail:
        php-gene...@lists.php.net


----------------------------------------------------------------------
--- Begin Message ---
Use Magento.  It will take you more than 6 months to build what you're
talking about all by yourself.  Magento is a pain to learn at first
but once you get into it things start to make sense and development
speeds up.

Marc

--- End Message ---
--- Begin Message ---
On Mon, Oct 22, 2012 at 4:06 PM, Mark <mark...@gmail.com> wrote:
>
> Hi,
>
> I'm in a difficult situation here. I have a list of requirements for an 
> eCommerce system (Magento) where i'm getting mixed opinions about what to do. 
> Note: i do consider myself to be a quite experienced PHP programmer and 
> certainly have the skills to either make the extensions or make everything 
> from scratch. Both do require month of work! First - for the complete picture 
> - the list of requirements for the eCommerce system:
> - (buld into magento) Multishop has to be possible
> - Different payment modules have to be possible (buckaroo, afterpay, ...)
> - Online chat (with for example zopim) has to be possible
> - Advanced product permissions (magento only has "manage" not more specific 
> as in "edit")
> - Setting pruduct margins
> - Abandoned cart alerts
> - One page checkout
> - Some javascript/ajax things like "instant cart"
> - A very specific order page (the "Booking and Reservations" plugin can do 
> that)
>
> Thus far it's all oke. However, if i go to the magento irc channel i'm 
> getting really mixed opinions about what to use and what to create myself. 
> They basically say that i should prevent installing as much extensions as 
> possible and try to make most of the things myself. This is where i'm getting 
> really confused.
>
> There are two possible routes to take here.
> 1. I can go for the magento route and just take the very steep learning curve 
> it has. It will be a slow process to make the modules required (mainly the 
> advanced permissions, setting product margins and a abandoned cart 
> extension). Two of those three are very difficult to make. Certainly if you 
> consider that i'm just starting developing in any eCommerce system.
>
> 2. Considering the steep learning curve of making extensions for Magento it 
> might be easier - in the long run - to build it all myself. In the beginning 
> that will be an even slower process then using Magento, but once the 
> structure is build it will be a much faster development process for any 
> extension.
>
> I know it's usually a bad thing to reinvent the wheel and i am certainly not 
> intending that. However, right now i really get the impression that i'm 
> better of making it all myself. Both approaches take many months of 
> development where the self made version is going to pay off in development 
> time in the long run when compared to magento. I am just not sure what the 
> best solution might be.
>
> So here is a list of pros and cons that i can think of for both approaches.
>
> Pros/Cons for using magento
> - [pro] a lot of existing extensions
> - [pro] i don't need to worry about security updates since the come from 
> magento
> - [pro] living community around it to help out if there are any issues
> - [con] very steep learning curve
> - [con] not straightforward to start developing in
> - [con] takes a lot of time till you can even use the basics
>
> Pros/Cons for self made
> - [pro] Development will go a lot faster
> - [pro] i can make it more specific for one goal
> - [pro] a much easier extension model
> - [con] security all depends on me
> - [con] i have to make complicated extensions like buckaroo and afterpay 
> myself
> - [con] no existing library of extensions to use
>
> Again, i'm puzzled by this. If i follow the #magento (on freenode) list then 
> i should pick magento, but make every extension myself or only use the really 
> good ones. Thus that will require a lot of time to develop them. I 'm 
> guessing about half a year. Then again, if i make it all from the ground up 
> it's probably also going to take half a year to develop (or slightly more) 
> but it will obviously be much easier to maintain since i know every single 
> line of it.
>
> What is your recommendation? Build it myself? Use Magento? or another option 
> that i didn't even consider yet?
>
> Kind regards,
> Mark

Something i made up just now. Would it work if i make the ecommerce
system myself and build OpenCart support in it so that OpenCart
extensions can be installed in my oscommerce as well? Since then i
wouldn't have to bother about payment modules.

Though it does add a very complex translation layer from "my to be
build oscommerce" to the OpenCart system...

--- End Message ---
--- Begin Message ---
Why not just use the entire OpenCart package?

--- End Message ---
--- Begin Message ---
On Mon, Oct 22, 2012 at 4:51 PM, Marc Guay <marc.g...@gmail.com> wrote:
> Why not just use the entire OpenCart package?
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>

Well, i was basing my choice of Magento on the "internet opinion" and
magento seems the most popular system out there to use with most of
the required extensions already there. OpenCart doesn't seem to be as
recommended as Magento..

--- End Message ---
--- Begin Message ---
Hi Daniel,

I think that the robot that manage the list is not sending you your own
emails.

Gerardo.

On Sat, Oct 20, 2012 at 10:38 AM, Daniel Brown <danbr...@php.net> wrote:

> On Sat, Oct 20, 2012 at 5:00 AM, Karl DeSaulniers <k...@designdrumm.com>
> wrote:
> > @Moderator
> > Any reason why my emails do not post or at least dont post for hours
> later?
>
>     There is no moderator on this list.  I'm probably about as close
> as it comes.  Can you explain more about the problems you're
> experiencing so that I can look into it further?
>
> --
> </Daniel P. Brown>
> Network Infrastructure Manager
> http://www.php.net/
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>


-- 
Gerardo Benitez
-------------------------
Programador Web Freelance

--- End Message ---
--- Begin Message ---
Strange, it did when I signed up and for a number of years after.


On Oct 22, 2012, at 10:09 AM, Gerardo Benitez wrote:

Hi Daniel,

I think that the robot that manage the list is not sending you your own emails.

Gerardo.

On Sat, Oct 20, 2012 at 10:38 AM, Daniel Brown <danbr...@php.net> wrote: On Sat, Oct 20, 2012 at 5:00 AM, Karl DeSaulniers <k...@designdrumm.com > wrote:
> @Moderator
> Any reason why my emails do not post or at least dont post for hours later?

    There is no moderator on this list.  I'm probably about as close
as it comes.  Can you explain more about the problems you're
experiencing so that I can look into it further?

--
</Daniel P. Brown>
Network Infrastructure Manager
http://www.php.net/

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




--
Gerardo Benitez
-------------------------
Programador Web Freelance


Karl DeSaulniers
Design Drumm
http://designdrumm.com


--- End Message ---
--- Begin Message ---
On Thu, Oct 18, 2012 at 2:12 AM, Ford, Mike <m.f...@leedsmet.ac.uk> wrote:

> > From: underp...@gmail.com [mailto:underp...@gmail.com] On Behalf Of
> > Richard S. Crawford
> > Sent: 17 October 2012 19:29
> > To: PHP-General
> >
> > You can see the current output of the above code here:
> >
> > http://projectbench.extensiondlc.net
>
> Can I ask what the fix for this was? Because that URL is currently
> showing the following for me:
>
> 02:09:27 am America/Los_Angeles
> America/Los_Angeles
> Thu, 18 Oct 2012 02:09:27 -0700
> Thu, 18 Oct 2012 09:09:27 +0000
> 1350551367 (-25200)
> Thu Oct 18 02:09:27 PDT 2012
>
>
> Cheers!
>
> Mike
>

Hi Mike,

Sorry I took so long to answer. I've been out sick, and didn't have access
to the resolution information until this morning.

The server administrators wound up reinstalling the tzdata package and
enabled time synchronization.



-- 
Sláinte,
Richard S. Crawford (rich...@underpope.com)
http://www.underpope.com
Publisher and Editor in Chief, Daikaijuzine (http://www.daikaijuzine.com)

--- End Message ---
--- Begin Message ---
Hello,

i have built php 5.4.7 on Ubuntu with the configure Arguments like on my 
Gentoo System. But on Gentoo run the website without Problems, under Ubuntu
want not work. I become in error.log:

[22-Oct-2012 21:15:00 UTC] PHP Fatal error:  Call to a member function 
prepare() on a non-object in html/index.html on line 23

U use PHP FPM with Nginx. 

The configure Arguments:
http://pastebin.geany.org/qz8TP/

The Script which work:
<?php
require_once ("db.php");

$query = $db->prepare("SELECT id, title, date FROM bloggen ORDER BY date DESC 
LIMIT 0,5");
if (!$query) {die("Execute query error, because: " . $db->errorInfo());}

$query->execute();

while ($row = $query->fetch(PDO::FETCH_ASSOC)) {
echo "<p><a href=\"/blog/post.html?id=".$row['id']."\" 
title=\"".(htmlentities($row['title'], ENT_QUOTES, 
"UTF-8"))."\">".(htmlentities($row['title'], ENT_QUOTES, "UTF-8"))."</a></p>\n";
}

$row = null;
$query = null;
$db = null;
?>


Has someone a idea what is there wrong?


Thanks for help and nice Day.

Silvio

--- End Message ---
--- Begin Message ---
On Mon, Oct 22, 2012 at 3:27 PM, Silvio Siefke <siefke_lis...@web.de> wrote:

> Hello,
>
> i have built php 5.4.7 on Ubuntu with the configure Arguments like on my
> Gentoo System. But on Gentoo run the website without Problems, under Ubuntu
> want not work. I become in error.log:
>
> [22-Oct-2012 21:15:00 UTC] PHP Fatal error:  Call to a member function
> prepare() on a non-object in html/index.html on line 23
>
> U use PHP FPM with Nginx.
>
> The configure Arguments:
> http://pastebin.geany.org/qz8TP/
>
> The Script which work:
> <?php
> require_once ("db.php");
>
> $query = $db->prepare("SELECT id, title, date FROM bloggen ORDER BY date
> DESC LIMIT 0,5");
> if (!$query) {die("Execute query error, because: " . $db->errorInfo());}
>

That looks like you've not connected to the database successfully inside of
db.php.

-nathan

--- End Message ---
--- Begin Message ---
On Mon, 2012-10-22 at 23:27 +0200, Silvio Siefke wrote:

> Hello,
> 
> i have built php 5.4.7 on Ubuntu with the configure Arguments like on my 
> Gentoo System. But on Gentoo run the website without Problems, under Ubuntu
> want not work. I become in error.log:
> 
> [22-Oct-2012 21:15:00 UTC] PHP Fatal error:  Call to a member function 
> prepare() on a non-object in html/index.html on line 23
> 
> U use PHP FPM with Nginx. 
> 
> The configure Arguments:
> http://pastebin.geany.org/qz8TP/
> 
> The Script which work:
> <?php
> require_once ("db.php");
> 
> $query = $db->prepare("SELECT id, title, date FROM bloggen ORDER BY date DESC 
> LIMIT 0,5");
> if (!$query) {die("Execute query error, because: " . $db->errorInfo());}
> 
> $query->execute();
> 
> while ($row = $query->fetch(PDO::FETCH_ASSOC)) {
> echo "<p><a href=\"/blog/post.html?id=".$row['id']."\" 
> title=\"".(htmlentities($row['title'], ENT_QUOTES, 
> "UTF-8"))."\">".(htmlentities($row['title'], ENT_QUOTES, 
> "UTF-8"))."</a></p>\n";
> }
> 
> $row = null;
> $query = null;
> $db = null;
> ?>
> 
> 
> Has someone a idea what is there wrong?
> 
> 
> Thanks for help and nice Day.
> 
> Silvio
> 


It's a bit odd that you're parsing all .html files as if they were PHP
(little bit of a waste, and does mean you'll have an extra step when
configuring a server to run the code)

That aside, I don't see 23 lines of code in your example, so I'm
assuming you've snipped a lot of the beginning (you've not mentioned in
particular which line in your excerpt is the 23rd). What's in your
db.php include? Are there any checks on whether a connection has been
established or not there?
-- 
Thanks,
Ash
http://www.ashleysheridan.co.uk



--- End Message ---
--- Begin Message ---
On Mon, Oct 22, 2012 at 5:27 PM, Silvio Siefke <siefke_lis...@web.de> wrote:
> Hello,
>
> i have built php 5.4.7 on Ubuntu with the configure Arguments like on my
> Gentoo System. But on Gentoo run the website without Problems, under Ubuntu
> want not work. I become in error.log:
>
> [22-Oct-2012 21:15:00 UTC] PHP Fatal error:  Call to a member function
> prepare() on a non-object in html/index.html on line 23
>

Can you show the code in db.php (just remember to remove any login
credentials)? It looks like there's an issue creating the $db object
you're using.

Adam



-- 
Nephtali:  A simple, flexible, fast, and security-focused PHP framework
http://nephtaliproject.com

--- End Message ---
--- Begin Message ---
Hello,


i found the mistake, i have forgetten write the new path for the sqlite 
database.


Thx
Silvio

--- End Message ---
--- Begin Message ---
Silvio Siefke wrote:
i found the mistake, i have forgetten write the new path for the sqlite
database.

Just been caught with a similar problem. Had moved a working site from windows to linux and it stopped serving up the swf files. Turns out the file has a hardcoded path with upper and lower case name, while the xml file was all lower case. Rename the folder with the right cases and it started working again :)

--
Lester Caine - G8HFL
-----------------------------
Contact - http://lsces.co.uk/wiki/?page=contact
L.S.Caine Electronic Services - http://lsces.co.uk
EnquirySolve - http://enquirysolve.com/
Model Engineers Digital Workshop - http://medw.co.uk
Rainbow Digital Media - http://rainbowdigitalmedia.co.uk

--- End Message ---
--- Begin Message --- I have a php script that has been triggered by my hoster's cron process(?) to run once a day since last March. It's been running fine - and I've made no changes to it. Suddenly in the last couple of days it is running twice it seems. The whole process sends an email at its conclusion and the receipient tells me today that she's getting two emails only a minute apart.

Any ideas on why this might happen? I haven't contact my host company yet - thought I'd ask around first.
--- End Message ---

Reply via email to