Jump to content

New to PHP. Need help with structure on existing site


RDavis

Recommended Posts

Hi all, I'm new to board so please be gentle.

 

I'm in the process of building a new site for a company however I still need to work on their existing site. The current site uses PHP, along with other things, and I have had no experience with it.

 

When I view source on the site through a browser I can clearly see the portion I need to edit (it's within a table tag). Now, when I download the index.php file from the ftp and load it in Dreamweaver for example I get a completely different code listing which does not include the section I need.

 

To be more specific, there is an image on the site that links to <root/catalog/index.php?cPath=80>. What I need to do is change the image that this link location displays along with changing the page that the link takes you to (possibly as simple as cPath= some other number). When I view source I can see the simple <a href> piece but it is nowhere in the PHP file. I have no concept of the structure that PHP uses and the site I have inherited has a directory structure much more complex than I am used to.

 

Any help would be appreciated.

Thanks,

R. Davis

Link to comment
Share on other sites

That sounds like some type of shopping cart possibly?  If so, then normally you'd be able to manage everything via some type of control panel.

 

Do you know anything of the software that is being used?  Homegrown, or some commericial application?

Link to comment
Share on other sites

Thank you for your help.

 

Yes, it is an e-comm/shopping cart system. It's called OScommerce. There is a control panel however it does not control this sort of material. Part of the reason I was hired was because the company had to pay someone $75 every time a thing like this had to be done "to the back end" according to the people they contacted.

 

It seems like a very professional and stable commercial application however since I did not construct the site and I have no experience with PHP I am having a tough time figuring out whatever functions and similar things are used and how.

 

Thanks again,

R.Davis

Link to comment
Share on other sites

OSCommerece is a very intuitive (perhaps too intuitive) system. It is designed by a lot of people online and has so much code that it is too much work to make it efficient and easy to work with. The image is going to be located in an images folder, I suggest downloading them and finding the image that way, and keep the name the same. That will be easier than trying to do it the other way.

 

The reason you do not see the code on the index.php page is because it uses massive includes and sometimes you have to go into about 5 or 6 different files to find the right file. Most of the files are located in the includes part under boxes etc. It is just a matter of finding the right files.

 

At anyrate, have fun OScommerece. I gave up on it and went with pinnaclecart.com  much easier and decently priced.

Link to comment
Share on other sites

I am able to find both the image I want to replace and the image I want to replace with. Are you saying I should rename a copy of the new image with the name of the image I want to replace? I don't have a problem doing that since it's only a quick fix until I get a new site up however I still need to change the path that the link points to.

 

In the 'includes' subdir there are a slew of subdir's and files. Will I see the html code in the correct one once I come across it just like I was viewing the source or will it be an endless chase of functions and such?

 

Although I am going to learn PHP the hard way I have already decided to use something other than OScommerce. I am looking at X-Cart right now but I have plenty of time to hunt around.

 

Thanks for your help,

R.Davis

Link to comment
Share on other sites

Yea just do the replace the image part and you will have your solution. That is actually what I did when I used OSCommerece.

 

Never heard of/used x-cart but yea. I will vouch for Pinnaclecart though, great system.

 

But yea OSCommerece is great and all, but really if you want to make money and have an easy system, it is not for you, spend the $600 on pinnacle cart lol.

Link to comment
Share on other sites

Okay, I understand that I can name my new photo with the name of the old photo and it will appear where the old one was. The problem now is that I still need to have that link to a different area. For example, if the link points to <root/catalog/index.php?cPath=80>, I now need that to point to <...cPath=23>. Is the only way to dig through each and every file in all the levels of the site structure? If so, will that bit of HTML text actually appear or will it something in PHP that I won't know to look for?

 

Thanks again for your help.

R.Davis

Link to comment
Share on other sites

art of the reason I was hired was because the company had to pay someone $75 every time a thing like this had to be done "to the back end" according to the people they contacted.

 

So now there paying you $50G a year to free free help from a forum? Seriously... how do you people get these gigs? :-)

 

Id'e sugest you learn php before you get cought. The link in my signiture would be a good place to start.

Link to comment
Share on other sites

Well, where do I start here.

 

First, they are paying me way more than $50,000 a year however the website was an afterthought to my contract at the company. In my first post I made it clear I had no PHP experience and was trying to answer a question. Now, a couple people have been nice enough to help point out a few things to me even if no one had answered my questions and I am sorry if you are longing for a job but if you cannot or will not help me it would be much more productive for you to say nothing at all than state the obvious that I need to learn PHP.

 

I thought this site was for fans of PHP and the forum was for new users to get help and advice. Sadly, I see that it is impossible to escape people like yourself. Now, before I delete my account and use your earth shattering advice of learning the syntax of the language let me offer you some advice...learn to run a spell check or speak properly. It's kinda funny when you say things as you did when you are using 6th grade grammar. Maybe that's how we get these jobs, we simply know to review a paragraph after typing it.

 

Thanks for those of you who tried to help me.

R.Davis

Link to comment
Share on other sites

Well, where do I start here.

 

First, they are paying me way more than $50,000 a year however the website was an afterthought to my contract at the company. In my first post I made it clear I had no PHP experience and was trying to answer a question. Now, a couple people have been nice enough to help point out a few things to me even if no one had answered my questions and I am sorry if you are longing for a job but if you cannot or will not help me it would be much more productive for you to say nothing at all than state the obvious that I need to learn PHP.

 

I thought this site was for fans of PHP and the forum was for new users to get help and advice. Sadly, I see that it is impossible to escape people like yourself. Now, before I delete my account and use your earth shattering advice of learning the syntax of the language let me offer you some advice...learn to run a spell check or speak properly. It's kinda funny when you say things as you did when you are using 6th grade grammar. Maybe that's how we get these jobs, we simply know to review a paragraph after typing it.

 

Thanks for those of you who tried to help me.

R.Davis

 

This is a help site, but we cannot help people who are not willing to read. OSCommerce is a massive system, that most people here do not know how to do the thing you are asking. Chances are this question is best directed to the OSCommerece forum, where people are fluent with the software. It is really not much of a PHP question as a "can you customize this for me" statement.

 

Really we are all just about as blind as you are with OSCommerece here unless someone dealt directly with it. I am not going to spend 2 days trying to search for what you need to do with the OSCommerece site and give you the answer and not get anything out of it. I suggest going to the correct forum, or doing as Thorpe suggest and read up on PHP Programming.

 

Its not that we do not want to help you, but your request is pretty unreasonable. You are assuming that everyone who is fluent at PHP has worked with your OSCommerece software.

 

Its not nice to assume.

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.