Click here to get back home

PHP(?) question

 HomeNewsGroups | Search | About
 comp.infosystems.www.authoring.html    Post an article   get this group's latest topics as an RSS feed add this group's latest topics to your My MSN content add this group's latest topics to your My Yahoo content
Subject Author Date
PHP(?) question firstcustomer 03-15-2006
Get Chitika Premium
Posted by firstcustomer on March 15, 2006, 3:13 am
Please log in for more thread options


Hi, I'm wanting to know if this is possible;

I've got a HTML page that is basically a text box with a botton that
copies the contents of the textbox to the clipboard (source code
below).

I'm wanting to know if there is a quick way to "dynamically" change the
contents of the text box (the contents are templated replies to
customer enquiries, and there are about 100 of them).

What I am wanting to do is to have[, for example] one page that is the
HTML (term used loosly as it could be in PHP or similar) that is the
text box and the copy button, and all the replies then in [for example]
text files.

Is there a way to get the HTML page to change the conents of the text
box. I have seen some URLs that have "site.php?content=contentname" in
them, is this what I would use?

Am I making any sense at all?

Anyway, here is the code:

<start>
<script language="JavaScript" src="IncludeFiles/ImageSwap.js"></script>


<script language="JavaScript">
function CloseScreen() {
        window.close();
}

function selectCode() {
var isMinIE4 = (document.all) ? 1 : 0;
var isMinIE5 = (isMinIE4 && navigator.appVersion.indexOf("5.")) >= 0 ?
1 : 0;
        if(document.frmKnowledgeBase.txtBody.value.length>0) {
                        document.frmKnowledgeBase.txtBody.focus();
                        document.frmKnowledgeBase.txtBody.select();
//                        //The code below only works with IE5.......
                        if (isMinIE5==true) {
                                var strBody = document.frmKnowledgeBase.txtBody.value;
                                window.clipboardData.setData("Text",strBody);
                        }
                        return false;
                }
        else {
                alert("Nothing for be selected");
                return false;
        }
}
</Script>
<html>
<head>
</head>

<body bgcolor="#FFFFFF" topmargin="0" leftmargin="0">

<form name="frmKnowledgeBase" onSubmit="return selectCode();">
<table width="100%" border="0" cellspacing="0" cellpadding="0"
height="100%">

<tr>
<td align="center" valign='top'><br>
<table width="90%" border="0" cellspacing="1" cellpadding="2"
align="center">

<tr>
<td width='10%'><b>Description</b></td>
<td colspan='2'>positive feedback</td>
</tr>
<tr>
<td width='10%' valign='top'><b>Body</b></td>
<td colspan='2'><textarea name='txtBody' rows='18'
style='background-color:#F2F2F2;width:100%;'>Dear XXXXX,

Thank you for your positive suggestions and feedback about
our website.

We have passed the points you raised on to our technical and
design support teams.

etc etc etc

blah blah blah

We hope you enjoy using our site and we look forward to your
next visit.

Regards

The website

</textarea></td>
<td colspan='2' valign='top' align='center'><b>Copy
to<br>Clipboard</b><br><input type='image' src='Clipboard.jpg'
id='image'1 name='image'1></td>
</tr>
</tr>

</table>
<br>
</td>
</tr>

</table>
</form>
</body>

</html>

</end>

TIA
--
Neil


Posted by hywel.jenkins on March 15, 2006, 9:06 am
Please log in for more thread options



firstcustomer@gmail.com wrote:
> Hi, I'm wanting to know if this is possible;
>
> I've got a HTML page that is basically a text box with a botton that
> copies the contents of the textbox to the clipboard (source code
> below).
>

Put them all in a database and use the querystring or post data to
determine which one to retrieve and display in the text box.

Why are you displaying them in the text box and making them available
to the clipboard? What happens once the data is on the clipboard?

--
Hywel


Posted by firstcustomer on March 15, 2006, 9:16 am
Please log in for more thread options



hywel.jenkins@gmail.com wrote:
> firstcustomer@gmail.com wrote:
> > Hi, I'm wanting to know if this is possible;
> >
> > I've got a HTML page that is basically a text box with a botton that
> > copies the contents of the textbox to the clipboard (source code
> > below).
> >
>
> Put them all in a database and use the querystring or post data to
> determine which one to retrieve and display in the text box.
>
> Why are you displaying them in the text box and making them available
> to the clipboard? What happens once the data is on the clipboard?
>

Hi Hywel, long time no see, thanks for that. I don't really understand
what you mean though, could you elaborate a little?
--
Neil


Posted by Neil Monk on March 15, 2006, 1:43 pm
Please log in for more thread options


firstcustomer@gmail.com wrote:
> hywel.jenkins@gmail.com wrote:
>> firstcustomer@gmail.com wrote:
>>> Hi, I'm wanting to know if this is possible;
>>>
>>> I've got a HTML page that is basically a text box with a botton that
>>> copies the contents of the textbox to the clipboard (source code
>>> below).
>>>
>>
>> Put them all in a database and use the querystring or post data to
>> determine which one to retrieve and display in the text box.
>>
>> Why are you displaying them in the text box and making them available
>> to the clipboard? What happens once the data is on the clipboard?
>>
>
> Hi Hywel, long time no see, thanks for that. I don't really understand
> what you mean though, could you elaborate a little?

Anyone....?
--
Neil
- www.neilmonk.com -
- Change the colour to Blue to email me -



Posted by firstcustomer on March 15, 2006, 10:02 am
Please log in for more thread options



hywel.jenkins@gmail.com wrote:
> firstcustomer@gmail.com wrote:
> > Hi, I'm wanting to know if this is possible;
> >
> > I've got a HTML page that is basically a text box with a botton that
> > copies the contents of the textbox to the clipboard (source code
> > below).
> >
> Why are you displaying them in the text box and making them available
> to the clipboard? What happens once the data is on the clipboard?

Sorry, forgot to address this bit in my earlier reply.

The user will then paste the response into an email system and send the
reply to the customer.


Similar ThreadsPosted
SSI question June 7, 2005, 11:58 am
OT - RSS Question July 21, 2005, 1:07 am
Another ALT question. February 9, 2006, 7:12 pm
CSS Question April 14, 2006, 2:05 pm
Question January 23, 2007, 8:39 pm
hyperlinks question July 21, 2004, 8:07 pm
domain question July 23, 2004, 2:04 am
Form Question August 10, 2004, 7:01 am
Question on the ID attribute of a Tag September 3, 2004, 12:16 pm
Question on MS Frontpage September 14, 2004, 6:12 pm

Our other projects:

Art Dolls, Fairies and Mermaids - Sunnyfaces.net

Roy's Linux, Programming and Search Engines messages

1-Script XML SitemapXML Sitemap