Ask a Question related to Macromedia Exchange Dreamweaver Extensions, Design and Development.
-
Jim Kennedy #1
Forms
Here's one option. Create a label in your form header (I
called mine blank). The label can say something
like "Sorry, there are no records."
Now add some code to the open event of the form. It
should look something like this:
Private Sub Form_Open(Cancel As Integer)
Dim rs As Object
Set rs = Me.RecordsetClone
If rs.RecordCount > 0 Then
Me.blank.Visible = False
Else
Me.blank.Visible = True
End If
End Sub
>-----Original Message-----
>I have a form that obtains its information from a query.
>All is well as long as the query has at least some
>output. However if the query is blank the from shows a a
>blank page. Is there a way to force the form to show
>there is no data?
>
>Thanks
>
>.
>Jim Kennedy Guest
-
FORMS - printing and emailing interactive forms
I'm using Acrobat 7 Pro on a Mac 10.4.8. I would like to create an interactive (order) form for my client to post on her website which her... -
Converting existing forms to the Flash forms
I have forms and I change all the tags on them, but they don't change to the new 'Flash forms' in CFMX 7. Any ideas on this? -
Advanced>Forms>Export Forms Data is grayed out
version 6.0.0 ¿ How do I activate this option ? -
Web Forms VS Windows Forms
What can a windows form do that a web form cannot? -
appletviewr plus forms 9i - crash on forms service
I'm trying to find workaround of the problem forms losing focus on IE6.0 on Windows XP using Jiniator. So I am trying to use appletviewer instead... -
Jamie Wright #2
Forms
I have a problem with an HTML form. I have a form which I want to be able to
type basic HTML code into it. When the submit button is selected the data is
then previewed and added back into the text box again. Unfortunately all of
the " charachters are escaped (I think that is the correct term) ie they
have a leading \ added. This is causing me huge problems. I don't understand
why that is happening. Any ideas?
------------------CODE--------------
<?PHP
if(!isset($contents))
{
include "config.php";
mysql_connect($cfg['dbhost'], $cfg['dbuser'], $cfg['dbpasswd']);
$query = "SELECT `text` FROM `golf_contents` WHERE 1 AND `section`
LIKE '$section'";
$result = mysql_db_query($cfg['dbname'], $query);
if ($result)
{
while ($r = mysql_fetch_array($result))
{
$contents=$r["text"];
}
}
}
$output = "
<html>
<head>
<title>
Edit Text
</title>
</head>
<body>
<form method=\"POST\" action=\"edittext.php?section=$section\">
<textarea rows=\"10\" name=\"contents\" cols=\"35\">
$contents
</textarea>
<input type=\"submit\" value=\"Preview\" name=\"B1\">
<input type=\"reset\" value=\"Reset\" name=\"B2\">
</form>
<BR>Preview...<BR>
$contents
</body>
</html>
";
echo $output;
?>
Jamie Wright Guest
-
Justin Koivisto #3
Re: Forms
Jamie Wright wrote:
Sounds like magic_quotes_gpc is enabled on your system. To get rid of> I have a problem with an HTML form. I have a form which I want to be able to
> type basic HTML code into it. When the submit button is selected the data is
> then previewed and added back into the text box again. Unfortunately all of
> the " charachters are escaped (I think that is the correct term) ie they
> have a leading \ added. This is causing me huge problems. I don't understand
> why that is happening. Any ideas?
them, before you create your output string, do this:
$contents=htmlentities(stripslashes($_POST['contents']));
stripslashes gets rid of the escape characters addslashes would add them
if you need them for a query or something
--
Justin Koivisto - [email]spam@koivi.com[/email]
PHP POSTERS: Please use comp.lang.php for PHP related questions,
alt.php* groups are not recommended.
Justin Koivisto Guest
-
Jamie Wright #4
Re: Forms
Cheers for that Justin. It seems to have solved one problem, but cleverly
created another. Now the
echo $output;
gives the HTML as plain text (tags and all). I'm not sure why this is
because in the text box it is as standard HTML. I'm very confused.
"Justin Koivisto" <spam@koivi.com> wrote in message
news:D7HMa.484$iA3.28926@news7.onvoy.net...able to> Jamie Wright wrote:
>> > I have a problem with an HTML form. I have a form which I want to bedata is> > type basic HTML code into it. When the submit button is selected theof> > then previewed and added back into the text box again. Unfortunately allunderstand> > the " charachters are escaped (I think that is the correct term) ie they
> > have a leading \ added. This is causing me huge problems. I don't>> > why that is happening. Any ideas?
> Sounds like magic_quotes_gpc is enabled on your system. To get rid of
> them, before you create your output string, do this:
>
> $contents=htmlentities(stripslashes($_POST['contents']));
>
> stripslashes gets rid of the escape characters addslashes would add them
> if you need them for a query or something
>
> --
> Justin Koivisto - [email]spam@koivi.com[/email]
> PHP POSTERS: Please use comp.lang.php for PHP related questions,
> alt.php* groups are not recommended.
>
Jamie Wright Guest
-
Justin Koivisto #5
Re: Forms
Jamie Wright wrote:
htmlentities transforms all characters to it's HTML equivalent.>
> "Justin Koivisto" <spam@koivi.com> wrote in message
> news:D7HMa.484$iA3.28926@news7.onvoy.net...
>>>>Jamie Wright wrote:
>>
>>>>>I have a problem with an HTML form. I have a form which I want to be
> able to
>>>>>type basic HTML code into it. When the submit button is selected the
> data is
>>>>>then previewed and added back into the text box again. Unfortunately all
> of
>>>>>the " charachters are escaped (I think that is the correct term) ie they
>>>have a leading \ added. This is causing me huge problems. I don't
> understand
>> Cheers for that Justin. It seems to have solved one problem, but cleverly>>>>>why that is happening. Any ideas?
>>Sounds like magic_quotes_gpc is enabled on your system. To get rid of
>>them, before you create your output string, do this:
>>
>>$contents=htmlentities(stripslashes($_POST['contents']));
>>
>>stripslashes gets rid of the escape characters addslashes would add them
>>if you need them for a query or something
>>
> created another. Now the
>
> echo $output;
>
> gives the HTML as plain text (tags and all). I'm not sure why this is
> because in the text box it is as standard HTML. I'm very confused.
Therefore, if you type in:
afdsg asdf "with </textarea> stuff"
in the textbox, that's how it should appear again, but the code will
look like:
afdsg asdf "with <html> stuff"
You need to do that because you want to preserve any quotes that are in
the content... Otherwise it could break the textarea if a "</textarea>"
was in the content.
Try this to see what I mean:
<?PHP
if(isset($_POST['contents'])){
$form_contents=htmlentities(stripslashes($_POST['contents']));
$contents=stripslashes($_POST['contents']);
}else{
$form_contents='';
$contents='';
}
?>
<html>
<head>
<title>Edit Text</title>
</head>
<body>
<form method="POST" action="">
<textarea rows="10" name="contents" cols="35"><?php echo
$form_contents ?></textarea>
<input type="submit" value="Preview" name="B1">
<input type="reset" value="Reset" name="B2">
</form>
<?php echo $contents ?>
</body>
</html>
--
Justin Koivisto - [email]spam@koivi.com[/email]
PHP POSTERS: Please use comp.lang.php for PHP related questions,
alt.php* groups are not recommended.
Justin Koivisto Guest
-
Jamie Wright #6
Re: Forms
> Try this to see what I mean:
<SNIP>>
> <?PHP
> if(isset($_POST['contents'])){
> $form_contents=htmlentities(stripslashes($_POST['contents']));
> $contents=stripslashes($_POST['contents']);
brilliant. I understand now. Thanks for your help.
Jamie
Jamie Wright Guest
-
Shawn Wilson #7
Re: Forms
Jamie Wright wrote:
This is happening because you're using htmlentities(). It's converting the <> Cheers for that Justin. It seems to have solved one problem, but cleverly
> created another. Now the
>
> echo $output;
>
> gives the HTML as plain text (tags and all). I'm not sure why this is
> because in the text box it is as standard HTML. I'm very confused.
and > (as well as other characters) into the html code, ie. < and >. Get
rid of it, keeping stripslashes() and your html tags will work.
Shawn
-->
>
> "Justin Koivisto" <spam@koivi.com> wrote in message
> news:D7HMa.484$iA3.28926@news7.onvoy.net...> able to> > Jamie Wright wrote:
> >> > > I have a problem with an HTML form. I have a form which I want to be> data is> > > type basic HTML code into it. When the submit button is selected the> of> > > then previewed and added back into the text box again. Unfortunately all> understand> > > the " charachters are escaped (I think that is the correct term) ie they
> > > have a leading \ added. This is causing me huge problems. I don't>> >> > > why that is happening. Any ideas?
> > Sounds like magic_quotes_gpc is enabled on your system. To get rid of
> > them, before you create your output string, do this:
> >
> > $contents=htmlentities(stripslashes($_POST['contents']));
> >
> > stripslashes gets rid of the escape characters addslashes would add them
> > if you need them for a query or something
Shawn Wilson
[email]shawn@glassgiant.com[/email]
[url]http://www.glassgiant.com[/url]
Shawn Wilson Guest
-
mk sabeel #8
forms
hello sir,
i have somehow been able to filter records using the
advanced filter technique. what i do is
i have a form, which has a subform1,which again has a
subform2. i first define by using advanced filter
design ,what feilds i want the filter to respond to (which
would display records of those respective feilds, i have
added using advanced filter).
i then click "select by form" button , then i scroll down
different feilds in the combo box type feilds of the form
(the feilds which ared dragged while working
with "advanced filter button".
i then click "apply filter" button and then i view the
forms that respond to the feilds i have choosen, by using
advanced filter . then finally i click "apply filter"
button to stop filtering.
what i am not able to achieve is that, when i choose a
feild from the subform to veiw my the records respective
to the feild in the subform only, it is not happening.
In the advanced filter option itself i cannot get the table
(from which i can drag feilds in advanced filter option)
which responds to the subform
please help me
also is their a way that i can refresh the form to a
default values so that when a user selects feilds on the
form ,after clicking "select by form" button he should not
see the feild values from the previous filtered values in
the feilds of the form.
what do i do, please help me
waiting for a stimualting response
thank you
sabeel
[email]mk_sabeel@yahoo.co.in[/email]
..
mk sabeel Guest
-
Milan #9
Forms
No VB required,
Put the first value in a combo-box that has two columns:
the value and the description. Then have a second control -
a text box whose control source is bound to the second
column of the combo-box.
For example the first value is called Code and the second
is called Desc. Have a combo-box called Code bound to the
field Code. The text box control source is in this case:
=Code.Column(1).
You don't need to requery anything, whenever you select
another value in the combobox, your text box will
automatically show to the new value.
P.S. You can leave both columns in the combo-box visible
or hide the second value (Desc) by setting width to 0;1
for example.
Milan
>-----Original Message-----
>How does one have a control where you input a value
>stored in a DB table, and a second control that displays
>the description of that value stored in the DB.
>
>Currently we can only see all the list of values, and all
>the descriptions of the values in two separate controls,
>list box and combo box respectively. Want only to input
>the value or select it incontrol A, and see the
>description in control B!
>
>I'm thinking we must write VB code or an expression, but
>have been trying to use a subform unsucessfully.
>.
>Milan Guest
-
Michelle A. #10
Forms
How do I use session variables to record information from multiple forms on
different pages and write them to an sql database using DWMX and asp.net
pages.?
Thanks..
Michelle A. Guest
-
John Vinson #11
Re: Forms
On 14 Jul 2003 11:36:57 -0700, [email]johnsonm@doj.state.wi.us[/email] (Miriam)
wrote:
What's the structure of your Table? A Form is JUST A TOOL - it's not a>I have 5 "combo" boxes in a single column in my database form. In
>each combo box is a drop down list of 10 server names(server names are
>the same in each drop down list). In the same form I also have a "tab
>control" box. I want to enhance the form so that when I select a
>server from the drop down list or click in the field, a
>seperate(dedicated) tab control box appears on screen for that
>particular server.
data storage medium; if you have five combo boxes on the Form bound to
five fields in your table it makes absolutely NO difference whether
the combo boxes are arranged vertically or horizontally or scattered
across the screen; if you have five *records* in a table, displayed on
a continous Form (which is probably a better design!) then you really
only have one combo box - just displayed five times.
What's your table structure? What's on these tab pages (again, a Tab
Page control doesn't contain any data; it's just a way to share screen
space among Form controls).
>*Note. The same server will never be selected multiple
>times(duplicated) in the column of combo boxes, however, if by
>accident a server was selected multiple times, I would like the
>corresponding tab box to appear for that particular server. Also, I'm
>using an old version-- Access 97.
>
>Thanks for your help,
>
>Miriam
John W. Vinson[MVP]
Come for live chats every Tuesday and Thursday
[url]http://go.compuserve.com/msdevapps?loc=us&access=public[/url]
John Vinson Guest
-
John Vinson #12
Re: Forms
On Wed, 16 Jul 2003 00:09:14 -0700, "Derrick" <dpharm@hotmail.com>
wrote:
What's your table structure? Where are these prices FROM? and do you>i have a form with a yes/no box for members and a textbox
>that should show prices for members or non-members
>depending on if the person is a member or not. I want
>that if the customer is a member then the price for the
>member shows and if not a member the non-member price
>shows.
want to store the appropriate price in the membership table, or just
display it?
John W. Vinson[MVP]
Come for live chats every Tuesday and Thursday
[url]http://go.compuserve.com/msdevapps?loc=us&access=public[/url]
John Vinson Guest
-
roudh webforumsuser@macromedia.com #13
Forms
Hi,
How can I make my submit button smaller?
Thanks.
roudh webforumsuser@macromedia.com Guest
-
roudh webforumsuser@macromedia.com #14
Re: Forms
Thanks for replying, but that would make the download size of my page bigger. Is there no way of making the actual button smaller by editing code? I tried to just add a <size="1"> tag to it, but that didn't work...
Also, I would like to know if there is a way of getting rid of the blank space that is created at the end of my forms - I don't seem to be able to make a image, or text appear <i>directly</i> after the form.
All replies greatly appreciated.
roudh webforumsuser@macromedia.com Guest
-
Dan Vendel *GOF* #15
Re: Forms
"roudh" [email]webforumsuser@macromedia.com[/email] wrote:
bigger. Is there no way of making the actual button smaller by editing> Thanks for replying, but that would make the download size of my page
code? I tried to just add a <size="1"> tag to it, but that didn't work...blank space that is created at the end of my forms - I don't seem to be>
> Also, I would like to know if there is a way of getting rid of the
able to make a image, or text appear <i>directly</i> after the form.It's nice to see someone actually being concerned about file size while>
> All replies greatly appreciated.
creating the page. A small gif with one or two colors, optimized, will
not be more than 5-6Kb, at most.
If you like to use code, use CSS as I said. But that might not work in
all browsers.
As for space at the bottom of the form, we need to see the page or the
code. Post a URL or the code.
--
Dan Vendel - *GOF*
[url]http://www.vendel.info[/url]
Contact me directly by clicking here:
[url]http://contact.vendel.info[/url]
Formmail tutorial:
[url]http://www.vendel.info/tut/formmail.html[/url]
Nested table demonstration:
[url]http://www.vendel.info/tabletut/[/url]
Dan Vendel *GOF* Guest
-
Derrick #16
Re: Forms
Have two tables; 1) tblPrices with members and non-
members prices and 2) tblCustomer that a member field
with data type yes/no. The tblustomer is the main form
and tblPrices is the subform. I want to display the price
in a text box on the form depending on if the customer is
a member or not and then create an invoice with the
price. Hope this is clearer.
<dpharm@hotmail.com>>-----Original Message-----
>On Wed, 16 Jul 2003 00:09:14 -0700, "Derrick"textbox>wrote:
>>>i have a form with a yes/no box for members and aFROM? and do you>>>that should show prices for members or non-members
>>depending on if the person is a member or not. I want
>>that if the customer is a member then the price for the
>>member shows and if not a member the non-member price
>>shows.
>What's your table structure? Where are these pricestable, or just>want to store the appropriate price in the membership>display it?
>
> John W. Vinson[MVP]
> Come for live chats every Tuesday and Thursday
>[url]http://go.compuserve.com/msdevapps?loc=us&access=public[/url]
>.
>Derrick Guest
-
Dinosaurus2 webforumsuser@macromedia.com #17
Forms
I'm a beginner DW user. I've put together a simple website, brokerabuse.com for a securities lawyer.
One of the pages is a form, with several blanks (fields) to be filled out by the visitors. I would like to receive the data input by visitors under the form of an e-mail. How should I do that?
Thanks in advance for any help,
Patricia
Dinosaurus2 webforumsuser@macromedia.com Guest
-
Dan Vendel *GOF* #18
Re: Forms
"Dinosaurus2" [email]webforumsuser@macromedia.com[/email] wrote:
1) Look in the DW help files. Press F1 -> Index -> "F" -> Forms> I'm a beginner DW user. I've put together a simple website, brokerabuse.com for a securities lawyer.
>
> One of the pages is a form, with several blanks (fields) to be filled out by the visitors. I would like to receive the data input by visitors under the form of an e-mail. How should I do that?
>
> Thanks in advance for any help,
>
> Patricia
>
>
>
2) Then, you need to make in work independantly of the users set-up. You
do that by sending the input from the form to a formmail script that in
turn mails it to the recipient.
Go here and look: [url]http://www.vendel.info/tut/formmail.html[/url]
--
Dan Vendel - *GOF*
[url]http://www.vendel.info[/url]
Contact me directly by clicking here:
[url]http://contact.vendel.info[/url]
Formmail tutorial:
[url]http://www.vendel.info/tut/formmail.html[/url]
Nested table demonstration:
[url]http://www.vendel.info/tabletut/[/url]
Dan Vendel *GOF* Guest
-
Kris Reid #19
Forms
I'm having trouble explaining this so please bare with me.
Say there is a form hosted on server A on a web page
Something simple like
<form action="submit.php" method="post" onSubmit="window.onunload=null;">
<input name="data" size="25" value="" /></td>
<input type="submit" value="submit" />
</form>
I have the data on server B in a mysql database that needs to be inserted via that form.
I have written a script that will grab one record and submit it via the form.
The only problem is I have to keep going back and refreshing my web page to get it to submit another record.
Is there a way of doing this? Please note I have no access to Server A so I can't just edit there database. Does this make sense? :)
Thanks
Kris
Kris Reid Guest
-
Andie #20
Forms
Hello
Can the following be done, I have tried to do it but without success
Basically I have a form, where I have 6 option boxes,
say Option box 1 has 3 options in it, being A,B,C. Is the a script around
than when a user selects an option them form gets reloaded with the same
option boxes, but between the first two option boxes a Text box appears with
a certain label, this labels is altered depenging on the users selection.
i.e
+---------------------------------------------------------+
| [OPTION BOX 1] (containing options A,B,C) |
|
|
|
|
| [OPTION BOX 2] (containing options A,B,C) |
|
|
+---------------------------------------------------------+
If a users selects option b in option box 1 then the form reloads like this
+---------------------------------------------------------+
| [OPTION BOX 1] (option B selected) |
| <label B> <textbox>
|
|
|
| [OPTION BOX 2] (containing options A,B,C) |
|
|
+---------------------------------------------------------+
I hope you understand what I am trying to do...
--
To reply, remove "TRASH" from email address
Thanks,
Andie
Andie Guest



Reply With Quote

