Deleted "echo" code

Amateur deleted small code string

Page 1 of 1

12 Replies - 1205 Views - Last Post: 31 March 2008 - 11:06 PM Rate Topic: -----

#1 alyab  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 7
  • Joined: 31-March 08

Deleted "echo" code

Posted 31 March 2008 - 08:55 PM

I'm completely new to this... If this is not the right forum, I apologize. I am using an ecommerce program at work, which is the backend of our website.

There are main default pages, and to add new pages, there is a form in which I directly add my content. Each page is made of 3 templates: top, mid, and bottom. The new content pages use a default mid template that had one tiny bit of code on it - which I accidentally deleted! :crazy:

It was very short
<---like this-->
and it had the word "echo" and at least one "?"
Apparently, all the template did, was tell the page to use my content in place of this empty template.

Since I deleted the code, none of my content pages are showing!! Is this a simple, basic common code???

I don't know what else is relevant, or if this is really the right forum for this.

Any help would be appreciated

Is This A Good Question/Topic? 0
  • +

Replies To: Deleted "echo" code

#2 no2pencil  Icon User is offline

  • Professor Snuggly Pants
  • member icon

Reputation: 6559
  • View blog
  • Posts: 30,699
  • Joined: 10-May 07

Re: Deleted "echo" code

Posted 31 March 2008 - 08:56 PM

What is the file extension for this code?
Was This Post Helpful? 0
  • +
  • -

#3 alyab  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 7
  • Joined: 31-March 08

Re: Deleted "echo" code

Posted 31 March 2008 - 09:03 PM

View Postno2pencil, on 31 Mar, 2008 - 08:56 PM, said:

What is the file extension for this code?



I don't understand your question. it was just a few characters in a <> tag

Thanks for trying to help me.

This post has been edited by alyab: 31 March 2008 - 09:04 PM

Was This Post Helpful? 0
  • +
  • -

#4 no2pencil  Icon User is offline

  • Professor Snuggly Pants
  • member icon

Reputation: 6559
  • View blog
  • Posts: 30,699
  • Joined: 10-May 07

Re: Deleted "echo" code

Posted 31 March 2008 - 09:05 PM

View Postalyab, on 31 Mar, 2008 - 09:03 PM, said:

I don't understand your question. it was just a few characters in a <> tag

<?php
  echo "Was it like this?";
?>



Is it possible that the code is archived somewhere? Like on a test system or something?
Was This Post Helpful? 0
  • +
  • -

#5 girasquid  Icon User is offline

  • Barbarbar
  • member icon

Reputation: 108
  • View blog
  • Posts: 1,825
  • Joined: 03-October 06

Re: Deleted "echo" code

Posted 31 March 2008 - 09:07 PM

He is wondering if you were working with a .php script, or a .shtml page - because the behavior is different in either case.

Based on your description, I think you removed the server side include tag from your template - do you have a backup anywhere you can restore from?
Was This Post Helpful? 0
  • +
  • -

#6 alyab  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 7
  • Joined: 31-March 08

Re: Deleted "echo" code

Posted 31 March 2008 - 09:14 PM

View Postgirasquid, on 31 Mar, 2008 - 09:07 PM, said:

He is wondering if you were working with a .php script, or a .shtml page - because the behavior is different in either case.

Based on your description, I think you removed the server side include tag from your template - do you have a backup anywhere you can restore from?


I came on board when this site was kind of laying around! It is way too easy to delete stuff. I make backups of the html code before I change anything, but I opened this template in error, and pasted something in instead of that tiny code... and saved it, before I realized it was the template.

Ouch.

Perhaps, there's a backup on the host server... but I can't contact them until tomorrow. I have no idea how that works. I definitely overrote the template. I think it may be a php. I can post screen shot of the backend area, maybe that can help you?
Was This Post Helpful? 0
  • +
  • -

#7 alyab  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 7
  • Joined: 31-March 08

Re: Deleted "echo" code

Posted 31 March 2008 - 09:20 PM

View Postalyab, on 31 Mar, 2008 - 09:14 PM, said:

View Postgirasquid, on 31 Mar, 2008 - 09:07 PM, said:

He is wondering if you were working with a .php script, or a .shtml page - because the behavior is different in either case.

Based on your description, I think you removed the server side include tag from your template - do you have a backup anywhere you can restore from?


I came on board when this site was kind of laying around! It is way too easy to delete stuff. I make backups of the html code before I change anything, but I opened this template in error, and pasted something in instead of that tiny code... and saved it, before I realized it was the template.

Ouch.


Perhaps, there's a backup on the host server... but I can't contact them until tomorrow. I have no idea how that works. I definitely overrote the template. I think it may be a php. I can post screen shot of the backend area, maybe that can help you?


I just looked at the software, I think it referred to a page called single_page.php ?
Was This Post Helpful? 0
  • +
  • -

#8 no2pencil  Icon User is offline

  • Professor Snuggly Pants
  • member icon

Reputation: 6559
  • View blog
  • Posts: 30,699
  • Joined: 10-May 07

Re: Deleted "echo" code

Posted 31 March 2008 - 09:31 PM

View Postalyab, on 31 Mar, 2008 - 09:14 PM, said:

I came on board when this site was kind of laying around! It is way too easy to delete stuff. I make backups of the html code before I change anything, but I opened this template in error, and pasted something in instead of that tiny code... and saved it, before I realized it was the template.

Ouch.

In your editor (if you still have the file open), you should be able to issue Control-Z & backtrack your steps past the save, bringing up the text that you deleted.
Was This Post Helpful? 0
  • +
  • -

#9 alyab  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 7
  • Joined: 31-March 08

Re: Deleted "echo" code

Posted 31 March 2008 - 09:38 PM

View Postno2pencil, on 31 Mar, 2008 - 09:31 PM, said:

View Postalyab, on 31 Mar, 2008 - 09:14 PM, said:

I came on board when this site was kind of laying around! It is way too easy to delete stuff. I make backups of the html code before I change anything, but I opened this template in error, and pasted something in instead of that tiny code... and saved it, before I realized it was the template.

Ouch.

In your editor (if you still have the file open), you should be able to issue Control-Z & backtrack your steps past the save, bringing up the text that you deleted.

You are really nice to be helping me. As I replied to girasquid, above... I saved it and overwrote the file... it took 2 seconds to screw up my website! The software people will easily be able to tell me what it said, but they are going to charge 3 arms, 6 legs, and my firstborn to tell me, so I figured if it was simple, maybe someone could make a suggestion. of what to try??
Was This Post Helpful? 0
  • +
  • -

#10 alyab  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 7
  • Joined: 31-March 08

Re: Deleted "echo" code

Posted 31 March 2008 - 09:49 PM

View Postgirasquid, on 31 Mar, 2008 - 09:07 PM, said:

He is wondering if you were working with a .php script, or a .shtml page - because the behavior is different in either case.

Based on your description, I think you removed the server side include tag from your template - do you have a backup anywhere you can restore from?


I think it was some form of <? echo >

that would be a variable for the tags of all the custom pages that use this template. Does that make sense??
Was This Post Helpful? 0
  • +
  • -

#11 alyab  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 7
  • Joined: 31-March 08

Re: Deleted "echo" code

Posted 31 March 2008 - 09:56 PM

By the way, you guys are awesome for working with me here. I feel so stupid!

no2pencil, your code above,

Quote

<?php
echo "Was it like this?";
?>


seems familiar
Was This Post Helpful? 0
  • +
  • -

#12 capty99  Icon User is offline

  • i am colt mccoy
  • member icon

Reputation: 99
  • View blog
  • Posts: 10,081
  • Joined: 26-April 01

Re: Deleted "echo" code

Posted 31 March 2008 - 10:41 PM

heres the thing... it could echo absolutely anything that was included earlier in your code, so we probably need to see your code to see.
Was This Post Helpful? 0
  • +
  • -

#13 no2pencil  Icon User is offline

  • Professor Snuggly Pants
  • member icon

Reputation: 6559
  • View blog
  • Posts: 30,699
  • Joined: 10-May 07

Re: Deleted "echo" code

Posted 31 March 2008 - 11:06 PM

View Postcapty99, on 31 Mar, 2008 - 10:41 PM, said:

heres the thing... it could echo absolutely anything that was included earlier in your code, so we probably need to see your code to see.

Absolutely, there could have been a variable that contained hundreds of lines of text that was read in from a database. & all the code did was echo out that one variable. Who knows?!
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1