Do you have a question? Post it now! No Registration Necessary.  Now with pictures!

Threaded View
I hope someone can help....

I'm new at all this, so please bear with me.  I created a website and did
this all in php using dreamweaver.  I later hired a programmer to connect
some forms and reports to an sql database.  I later had him upload all the
files to the server.

Now, I need to be able to go in and edit some of the content - not touching
the database.  When i download the files from the server and open them again
in Dreamweaver, all the content within the body tags seem to be replaced
with something like:

<? view_content(78) ?>  -each php page will have a different number - this
one happens to be 78.

Does this mean that the programmer took all my content out and put that into
the database as well?

If so...why would they do that?  Any reaon from a programming view point?
Or just making the pages load faster?  Or making it impossible for me to
edit content so I need to re-hire him each time I need changes?

Thanks everyone,




Abe wrote:
Quoted text here. Click to load it

First of all, you hired a crappy programmer. Using <? in stead of <?php
is not something a decent PHP programmer would do these days. But that
doesn't solve your problem.

'view_content()' is most likely a function, so it might be best to check
in which file this function is located and what the function does. It
could be this function gets the content out of a database, which is not
bad at all, only his implementation is bad. Almost every PHP website
gets the actual page content out of a database. I suspect that, he has a
'content' table where each page corresponds to a specific ID and he
fetches the content depending on that ID. To edit the page you thus need
to edit the content directly inside the database, or, if provided, via
the administration section of your website. But, that merely depends on
the exact implementation of the 'view_content()' function.

- Jensen

Jensen Somers <
Email: -http:// +jensen@

"Programming today is a race between software engineers striving to
build bigger and better idiot-proof programs, and the Universe trying to
produce bigger and better idiots. So far, the Universe is winning."
   - Rick Cook, The Wizardry Compiled


thanks for your help....I'll dig deeper.

Quoted text here. Click to load it


Abe wrote:
Quoted text here. Click to load it

OK. I'm a php newbie so I'll try to help.

  I created a website and did
Quoted text here. Click to load it

   It's somewhere. Not necessarily in a database.

Look for that function "view_content". It may be in an included file.
Then you'll have a clue where your content is.
Quoted text here. Click to load it

Well if everything between the body tags is gone, then it is awkward way
of working. If only the editable part of the page, then that could be
some Content Management System.

Quoted text here. Click to load it

   Have you tried asking him.

Quoted text here. Click to load it


Quoted text here. Click to load it

IMO you would have been a lot further ahead to have first asked the
programmer.  He might have given you a quick answer and you'd be back to
work by now instead of trying to ferret everything out covertly.  I
think your programmer should have had first crack at answering your
questions and then, if you weren't satisfied, you would have come here
armed with much more powerful descriptions.
   So give the guy/gal a chance; you hired him, accepted the work and
paid him at least partially, so now if there seem to be problems it's
only ethical/reasonable to see what his response would be.  It's a
totally acceptable thing to do, especially since your'e a newbie at PHP.
   I'll never forget the guy who hired a chimney contractor to inspect
his chimney next door to us in Chgo, and complained because the only
"test" equipment the guy used was a mirror in the cleanout trap, for
about 15 minutes, on a nice, bright sunny day.  He paid the next guy who
used a camera 8 times what he paid the first guy, to get the same
identical report; the liner was falling apart.  I'm only saying, it's
reasonable to ask because the one who did the work knows what he did and
why.  THEN if his answers aren't good, you have something to work with.
   Actually, this sounds more like you didn't know what you wanted and
he didn't give you a description of what he planned to do before he
started - two mistakes, but only one probably avoidable.

Just my 2


Site Timeline