Welcome to MobyThreads.com!
FAQFAQ      ProfileProfile    Private MessagesPrivate Messages   Log inLog in
All support for the MobyThreads Threaded phpBB MOD can now be found on welsolutions at this forum

very simple one line cms?

 
   Web Hosting and Web Master Forums (Home) -> Webmaster RSS
Next:  Web host seemingly out of business - how do I mov..  
Author Message
user525

External


Since: Jul 12, 2004
Posts: 21



(Msg. 1) Posted: Tue Aug 03, 2004 1:00 pm
Post subject: very simple one line cms?
Archived from groups: alt>www>webmaster, others (more info?)

hi all
i need to have a page on a clients site that has a competition question that
changes weekly.
they need to be able to change the question through some kind of admin page
(i was going to make a separate page that was password protected for this
purpose).
now i am thinking using MySQL etc will be like using a sledghammer to crack
a nut open, and am wondering if there is some simpler way of implementing
this using maybe basic PHP and an external text file or something? or maybe
i dont even require PHP?
any ideas appreciated.
thanks

 >> Stay informed about: very simple one line cms? 
Back to top
Login to vote
user550

External


Since: Aug 03, 2004
Posts: 1



(Msg. 2) Posted: Tue Aug 03, 2004 1:01 pm
Post subject: Re: very simple one line cms? [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

"1" <1.TakeThisOut@1.com> kirjoitti viestissä news:2n92i8Fu0kimU1@uni-berlin.de...
 > hi all
 > i need to have a page on a clients site that has a competition question
that
 > changes weekly.

If its okay, why not include a textfile inside pre-tags or you can also put
string trough this kind of php-function

function html_inclusion($file)
{
- open that file into string
- put string trough htmlspecialchars (maybe do striptags first)
- str_replace \n with <br>
- echo that string
}

then they can use ftp to update that textfile<!-- ~MESSAGE_AFTER~ -->

 >> Stay informed about: very simple one line cms? 
Back to top
Login to vote
blthecat

External


Since: Feb 27, 2004
Posts: 16



(Msg. 3) Posted: Tue Aug 03, 2004 8:59 pm
Post subject: Re: very simple one line cms? [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

I noticed that Message-ID: <2n92i8Fu0kimU1.RemoveThis@uni-berlin.de> from 1
contained the following:

 >hi all
 >i need to have a page on a clients site that has a competition question that
 >changes weekly.
 >they need to be able to change the question through some kind of admin page
 >(i was going to make a separate page that was password protected for this
 >purpose).
 >now i am thinking using MySQL etc will be like using a sledghammer to crack
 >a nut open,
Maybe, but you could do other cool stuff like put in a load of
questions and having them change each week automatically. I've used a
database for a list of events and found it worth its weight in gold.
Set it and forget it. Of course you can charge the client for weekly
updates..Smile

But if you just want to write to a text file, I posted a script a few
days ago that allows you to do just that. You'll have to hack it a bit.

<a style='text-decoration: underline;' href="http://www.ckdog.co.uk/logger/display.php" target="_blank">www.ckdog.co.uk/logger/display.php</a>

To edit the file:
<a style='text-decoration: underline;' href="http://www.ckdog.co.uk/logger/editlog.php" target="_blank">http://www.ckdog.co.uk/logger/editlog.php</a>

Let me know if you want it.
--
Geoff Berrow (put thecat out to email)
It's only Usenet, no one dies.
My opinions, not the committee's, mine.
Simple RFDs <a style='text-decoration: underline;' href="http://www.ckdog.co.uk/rfdmaker/" target="_blank">http://www.ckdog.co.uk/rfdmaker/</a><!-- ~MESSAGE_AFTER~ -->
 >> Stay informed about: very simple one line cms? 
Back to top
Login to vote
usenet200408

External


Since: Aug 02, 2004
Posts: 145



(Msg. 4) Posted: Tue Aug 03, 2004 10:10 pm
Post subject: Re: very simple one line cms? [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

1 wrote:

 > i need to have a page on a clients site that has a competition question that
 > changes weekly.

Do you also need to collect the answers to the competition? Or are those
collected by e-mail or something?

--
Toby A Inkster BSc (Hons) ARCS
Contact Me ~ <a style='text-decoration: underline;' href="http://tobyinkster.co.uk/contact" target="_blank">http://tobyinkster.co.uk/contact</a>
Now Playing ~ ./dido/life_for_rent/02_-_stoned.ogg<!-- ~MESSAGE_AFTER~ -->
 >> Stay informed about: very simple one line cms? 
Back to top
Login to vote
nospam34

External


Since: Oct 20, 2003
Posts: 294



(Msg. 5) Posted: Tue Aug 03, 2004 10:33 pm
Post subject: Re: very simple one line cms? [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

1 wrote:

 > hi all
 > i need to have a page on a clients site that has a competition question
 > that changes weekly.
 > they need to be able to change the question through some kind of admin
 > page (i was going to make a separate page that was password protected for
 > this purpose).
 > now i am thinking using MySQL etc will be like using a sledghammer to
 > crack a nut open, and am wondering if there is some simpler way of
 > implementing this using maybe basic PHP and an external text file or
 > something? or maybe i dont even require PHP?
 > any ideas appreciated.
 > thanks

I use <a style='text-decoration: underline;' href="http://www.mamboserver.com" target="_blank">www.mamboserver.com</a> for my personal site (see signature).
Its a Content Management System based on PHP.

Mambo allows for website content to have a start date & end date. So a new
question would appear at the appropriate time


gtoomey
<a style='text-decoration: underline;' href="http://www.gregorytoomey.com" target="_blank">www.gregorytoomey.com</a><!-- ~MESSAGE_AFTER~ -->
 >> Stay informed about: very simple one line cms? 
Back to top
Login to vote
user525

External


Since: Jul 12, 2004
Posts: 21



(Msg. 6) Posted: Tue Aug 03, 2004 10:33 pm
Post subject: Re: very simple one line cms? [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

yup i do too, but its way too much just for this system.
i need a really simple form with one text field, when they hit submit it
publishes to the page...
thanks


"Gregory Toomey" <nospam.DeleteThis@bigpond.com> wrote in message
news:2n94fkFt9tqsU1@uni-berlin.de...
 > 1 wrote:
 >
  > > hi all
  > > i need to have a page on a clients site that has a competition question
  > > that changes weekly.
  > > they need to be able to change the question through some kind of admin
  > > page (i was going to make a separate page that was password protected
for
  > > this purpose).
  > > now i am thinking using MySQL etc will be like using a sledghammer to
  > > crack a nut open, and am wondering if there is some simpler way of
  > > implementing this using maybe basic PHP and an external text file or
  > > something? or maybe i dont even require PHP?
  > > any ideas appreciated.
  > > thanks
 >
 > I use <a style='text-decoration: underline;' href="http://www.mamboserver.com" target="_blank">www.mamboserver.com</a> for my personal site (see signature).
 > Its a Content Management System based on PHP.
 >
 > Mambo allows for website content to have a start date & end date. So a
new
 > question would appear at the appropriate time
 >
 >
 > gtoomey
<font color=purple> > <a style='text-decoration: underline;' href="http://www.gregorytoomey.com</font" target="_blank">www.gregorytoomey.com</font</a>><!-- ~MESSAGE_AFTER~ -->
 >> Stay informed about: very simple one line cms? 
Back to top
Login to vote
steve6

External


Since: Jul 15, 2004
Posts: 40



(Msg. 7) Posted: Tue Aug 03, 2004 10:33 pm
Post subject: Re: very simple one line cms? [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

In news:2n95a1Fuf6sgU1@uni-berlin.de,
1 <1 RemoveThis @1.com> said:
 > yup i do too, but its way too much just for this system.
 > i need a really simple form with one text field, when they hit submit
 > it publishes to the page...
 > thanks

I would allow this form just to write to a text file, and the webpage can
just pull the content from the text file using PHP or server-side includes
or whatever you have at your disposal.


--
Steve<!-- ~MESSAGE_AFTER~ -->
 >> Stay informed about: very simple one line cms? 
Back to top
Login to vote
user525

External


Since: Jul 12, 2004
Posts: 21



(Msg. 8) Posted: Tue Aug 03, 2004 10:33 pm
Post subject: Re: very simple one line cms? [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

yup that would be exactly it.
any pointers on how to accomplish this? i am a bit of a newbie as far as php
is concerned.
thanks

"Steve" <steve DeleteThis @somewhere.invalid.com> wrote in message
news:zxJPc.21058179$Of.3498241@news.easynews.com...
 > In news:2n95a1Fuf6sgU1@uni-berlin.de,
 > 1 <1 DeleteThis @1.com> said:
  > > yup i do too, but its way too much just for this system.
  > > i need a really simple form with one text field, when they hit submit
  > > it publishes to the page...
  > > thanks
 >
 > I would allow this form just to write to a text file, and the webpage can
 > just pull the content from the text file using PHP or server-side includes
 > or whatever you have at your disposal.
 >
 >
 > --
 > Steve
 >
 ><!-- ~MESSAGE_AFTER~ -->
 >> Stay informed about: very simple one line cms? 
Back to top
Login to vote
user551

External


Since: Aug 03, 2004
Posts: 1



(Msg. 9) Posted: Tue Aug 03, 2004 10:33 pm
Post subject: Re: very simple one line cms? [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

This may help, may not:
Hope it does.

PAGE 1
*************** ADDS NEW QUESTION FORM AND WRITES THE TO QUESTION.TXT
PAGE *********************


<?php
$filename = "question.txt";
$seperator = "/ENDOFLINE/";
if (isset ($_POST['Submit'])){
  $new_question = sprintf ("%s$seperator\r\n%s$seperator\r\n",
addslashes($_POST['question']), addslashes($_POST['answer']));
  if (!$handle = fopen($filename, "r+")){
   echo "cannot open file to edit question";
   exit;
  }
  fwrite ($handle, $new_question);
  fclose ($handle);
  header ("Location:viewquestion.php");
  exit;
}
?>

<form action="<?php echo $_SERVER['PHP_SELF']; ?>"
method="post">question:<input name="question" type="text"><br>
answer:<input name="answer" type="text"><br>
<input name="Submit" type="submit" value="Submit">
</form>



PAGE 2
********* WILL PLACE ALL OF THE QUESTIONS AND ANSWERS INTO AN ARRAY
******
**** >SPLIT THEM UP INTO A QUESTIONS AND ANSWERS ARRAY IF YOU WISH<
******

<?php
$filename = "question.txt";
$seperator = "/ENDOFLINE/";

if (!$handle = fopen ($filename, "r")){
  echo "cannot access question file";
  exit;
}
$contents = fread ($handle, filesize ($filename));
fclose ($handle);

$all = explode ($seperator, $contents);
foreach ($all as $question){
  echo stripslashes($question).'<br>';
}
?><!-- ~MESSAGE_AFTER~ -->
 >> Stay informed about: very simple one line cms? 
Back to top
Login to vote
user525

External


Since: Jul 12, 2004
Posts: 21



(Msg. 10) Posted: Wed Aug 04, 2004 1:54 pm
Post subject: Re: very simple one line cms? [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

yeah collect the answers too
undecided if this will be by email or not

"Toby Inkster" <usenet200408 RemoveThis @tobyinkster.co.uk> wrote in message
news:pan.2004.08.03.18.10.40.274694@tobyinkster.co.uk...
 > 1 wrote:
 >
  > > i need to have a page on a clients site that has a competition question
that
  > > changes weekly.
 >
 > Do you also need to collect the answers to the competition? Or are those
 > collected by e-mail or something?
 >
 > --
 > Toby A Inkster BSc (Hons) ARCS
<font color=purple> > Contact Me ~ <a style='text-decoration: underline;' href="http://tobyinkster.co.uk/contact</font" target="_blank">http://tobyinkster.co.uk/contact</font</a>>
 > Now Playing ~ ./dido/life_for_rent/02_-_stoned.ogg
 ><!-- ~MESSAGE_AFTER~ -->
 >> Stay informed about: very simple one line cms? 
Back to top
Login to vote
Display posts from previous:   
Related Topics:
on-line shop - Quick and Simple? - Hi - I hope someone can help. I've been asked to produce an online shop for a client with a current portfolio of around 50 products to be sold primarily here in the UK. Whilst I have a lot of XHTML / CSS / Javascript experience I am but a newbie to the...

on-line games - I've taken over a fairly large, but boring alumni association web site. I'd like to install some on-line games the alums can play (either on their own or against one another) while visiting the site. Any suggestions? TIA Doug..

60 characters per line - Hey, I have a question. I have several articles in which I am thinking about submitting to a few ezines. Most ezines stipulate that they would like submitted articles to be 60 characters per line. This is ok. However, when I bring up my articles in..

[...line to long...] was $5 setup fee. - "John Bokma" <postmaster@castleamber.com> wrote in message news:40dfd506$0$863$58c7af7e@news.kabelfoon.nl... <font color=purple> ;> Heidi wrote:</font> <font color=purple> ;></font> <font c...

Posting a spreadsheet on line - Was trying to dig out info and ran out of ideas...came into my news section and found this listing... I intend or would desire to place a spreadsheet within my site and extract certain cells into a template or page that will display certain..
   Web Hosting and Web Master Forums (Home) -> Webmaster All times are: Pacific Time (US & Canada) (change)
Page 1 of 1

 
You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum



[ Contact us | Terms of Service/Privacy Policy ]