|
Did you look at Drupal as an alternative to Wordpress? It's very strong on internationalisation. [having just typed that, I can see why it's called i18n! ]
Peter
Software rusts. Simon Stephenson, ca 1994.
|
|
|
|
|
I would appreciate if you share 
|
|
|
|
|
Hi everyone,
I have problem with form at my site. When you fill the text boxes it works fine but when you click SEND, the site is refreshing, form is clear and no message has been sent. My knowledge about PHP is very low. I found the tutorial which shows how to make that kind of form.
form is on this site --> www.hogar-biokominki.pl/jak_kupic.html
I have 3 files which operate the form.
first file: formularz.php
<div class="form" >
<form action="jak_kupic.php" method="post" id="form1">
<input type="hidden" name="sender" value="true">
Formularz kontaktowy
<label for="imieinazwisko">Imię i Nazwisko:</label>
<input name="imieinazwisko" type="text" id="imieinazwisko" tabindex="1" maxlength="30">
Pole wymaganeZa mało znaków
<label for="adresemail2">Adres e-mail:</label>
<input type="text" name="adresemail" id="adresemail2" tabindex="2">
Błędny adres emailBłędny adres e-mail
<label for="walidacjaemail">Podaj ponownie e-mail:</label>
<input type="text" name="walidacjaemail" id="walidacjaemail" tabindex="3">
Pole wymaganeAdres się nie zgadza
<label for="numertelefonu">Telefon:</label>
<input type="text" name="numertelefonu" id="numertelefonu" tabindex="4">
Niewłaściwy numerNiewłaściwy numerZa mało cyfr
<label for="miasto">Miasto:</label>
<input name="miasto" type="text" id="miasto" tabindex="5" maxlength="15">
<label for="wiadomosc2">Wiadomość:</label>
<textarea name="wiadomosc" id="wiadomosc2" cols="45" rows="5" tabindex="6"></textarea>
Pole wymaganeZa mało znaków
<input type="submit" name="wyslij" id="wyslij" value="Wyślij" tabindex="6">
</form>>
second file: jak_kupic.html (I paste only form's DIV)
<div class="form">
<form action="" method="post" name="form1" id="form1">
<fieldset>
<legend>Formularz kontaktowy</legend>
<li><span id="sprytextfield1">
<label for="imieinazwisko">Imię i Nazwisko:</label>
<input name="imieinazwisko" type="text" id="imieinazwisko" tabindex="1" maxlength="30">
<span class="textfieldRequiredMsg">Pole wymagane</span><span class="textfieldMinCharsMsg">Za mało znaków</span></span></li>
<li><span id="sprytextfield2">
<label for="adresemail2">Adres e-mail:</label>
<input type="text" name="adresemail" id="adresemail2" tabindex="2">
<span class="textfieldRequiredMsg">Błędny adres email</span><span class="textfieldInvalidFormatMsg">Błędny adres e-mail</span></span></li>
<li><span id="spryconfirm1">
<label for="walidacjaemail">Podaj ponownie e-mail:</label>
<input type="text" name="walidacjaemail" id="walidacjaemail" tabindex="3">
<span class="confirmRequiredMsg">Pole wymagane</span><span class="confirmInvalidMsg">Adres się nie zgadza</span></span>
</li>
<li><span id="sprytextfield3">
<label for="numertelefonu">Telefon:</label>
<input type="text" name="numertelefonu" id="numertelefonu" tabindex="4">
<span class="textfieldInvalidFormatMsg">Niewłaściwy numer</span><span class="textfieldMinCharsMsg">Niewłaściwy numer</span><span class="textfieldMinValueMsg">Za mało cyfr</span></span></li>
<li>
<label for="miasto">Miasto:</label>
<input name="miasto" type="text" id="miasto" tabindex="5" maxlength="15">
</li>
<li>
<span id="sprytextarea1">
<label for="wiadomosc2">Wiadomość:</label>
<textarea name="wiadomosc" id="wiadomosc2" cols="45" rows="5" tabindex="6"></textarea>
<span class="textareaRequiredMsg">Pole wymagane</span><span class="textareaMinCharsMsg">Za mało znaków</span></span></li>
<li>
<input type="submit" name="wyslij" id="wyslij" value="Wyślij" tabindex="6">
</fieldset>
</form>
</li>
</ul>
</div>
third file: jak_kupic.php (pasted only form's DIV)
<div class="form_field">
<img src="images/jak_zamawiac_02.jpg" width="1024" height="661" alt="formularz">
<?
if(isset($_POST["sender"]))
{
$imie=$_POST['imieinazwisko'];
$email=$_POST['adresemail'];
$telefon=$_POST['telefon'];
$miasto=$_POST['miasto'];
$wiadomosc=$_POST['wiadomosc'];
$reply_subject= 'Zapytanie ze strony Hogar';
$reply_body = 'Witamy serdecznie,\nOtrzymaliśmy Państwa wiadomość. Odezwiemy się najprędzej jak to mozliwe.\n\nZ poważaniem\nBiokominki Hogar';
$reply_email = 'biuro@hogar-biokominki.pl';
$to = 'biuro@hogar-biokominki.pl';
$from = $imie . "<" . $email .">";
$subject = 'Zapytanie ze strony Hogar';
$body="\n\nImię i Nazwisko" . $imie . "\n\nEmail: " . $email . "\n\nTelefon" . $telefon . "\n\nMiasto" . $miasto . "\n\nWiadomość:" . $wiadomosc;
$coding = "Content-Type: text/plain; charse=utf-8 \nContent-Transfer-Encoding: 8bit";
if(mail($to, $subject, $body, "From: " . $from . "\n" . $coding))
{
if(mail($email, $reply_subject, $reply_body, "From: " . $reply_email . "\n" . $coding))
{
echo"<p class=\"dziekujemy\"> Dziekujemy za wysłanie wiadomości!</p>";
}
else
{
echo"<p class=\"dziekujemy\">Formularz nie został wysłany. Spróbuj ponownie.</p>";
}
}
}
require_once("formularz.php");
?>
</div>
Strange thing is that I can send form from /jak_kupic.php and it works. But layout sucks. But I can't send from /jak_kupic.html.
Can I connect these two files somehow?
|
|
|
|
|
You can post the form to the 'jak_kupic.html' but keep in mind that this is a static page, so it won't be able to handle your post data.
So you should post to a PHP page if you want the form to be processed server side. You PHP could then include the 'jak_kupic.html' when the form process is done and succesfull. You can do this by including the following line of code after the form processing:
|
|
|
|
|
 I have pasted formularz.php to jak_kupic.php and it is not working too. I get some errors.
I have now jak_kupic.php looks like that:
<div class="form_field">
<img src="../Documents/WEBSITES/Hogar/www/images/jak_zamawiac_02.jpg" width="1024" height="661" alt="formularz">
<?
$imie=$_POST['imieinazwisko'];
$email=$_POST['adresemail'];
$telefon=$_POST['numertelefonu'];
$miasto=$_POST['miasto'];
$wiadomosc=$_POST['wiadomosc'];
$reply_subject= 'Zapytanie ze strony Hogar';
$reply_body = 'Dziekujemy za kontakt. Odezwiemy sie wkrotce.';
$reply_email = 'biuro@hogar-biokominki.pl';
$to = 'biuro@hogar-biokominki.pl';
$from = $imie . "<" . $email .">";
$subject = 'Zapytanie ze strony Hogar';
$body="\n\nImię i Nazwisko: " . $imie . "\n\nEmail: " . $email . "\n\nTelefon: " . $numertelefonu . "\n\nMiasto: " . $miasto . "\n\nWiadomość:" . $wiadomosc;
$coding = "Content-Type: text/plain; charse=utf-8 \nContent-Transfer-Encoding: 8bit";
if(mail($to, $subject, $body, "From: " . $from . "\n" . $coding))
{
if(mail($email, $reply_subject, $reply_body, "From: " . $reply_email . "\n" . $coding))
{
echo"<p class=\"dziekujemy\"> Dziękujemy za wysłanie wiadomości!</p>";
}
else
{
echo"<p class=\"dziekujemy\">Formularz nie został wysłany. Spróbuj ponownie.</p>";
}
}
if(isset($_POST['sender'])) { echo "style=\"display:none;\""; } ?>>
<form action="../Documents/WEBSITES/Hogar/www/jak_kupic.php" method="post" id="form1">
<input type="hidden" name="sender" value="true">
<fieldset>
<legend>Formularz kontaktowy</legend>
<li><span id="sprytextfield1">
<label for="imieinazwisko">Imię i Nazwisko:</label>
<input name="imieinazwisko" type="text" id="imieinazwisko" tabindex="1" maxlength="30">
Pole wymaganeZa mało znaków</span></li>
<li><span id="sprytextfield2">
<label for="adresemail2">Adres e-mail:</label>
<input type="text" name="adresemail" id="adresemail2" tabindex="2">
Błędny adres emailBłędny adres e-mail</span></li>
<li><span id="spryconfirm1">
<label for="walidacjaemail">Podaj ponownie e-mail:</label>
<input type="text" name="walidacjaemail" id="walidacjaemail" tabindex="3">
Pole wymaganeAdres się nie zgadza</span>
</li>
<li><span id="sprytextfield3">
<label for="numertelefonu">Telefon:</label>
<input type="text" name="numertelefonu" id="numertelefonu" tabindex="4">
Niewłaściwy numerNiewłaściwy numerZa mało cyfr</span></li>
<li>
<label for="miasto">Miasto:</label>
<input name="miasto" type="text" id="miasto" tabindex="5" maxlength="15">
</li>
<li>
<span id="sprytextarea1">
<label for="wiadomosc2">Wiadomość:</label>
<textarea name="wiadomosc" id="wiadomosc2" cols="45" rows="5" tabindex="6"></textarea>
Pole wymaganeZa mało znaków</span></li>
<li>
<input type="submit" name="wyslij" id="wyslij" value="Wyślij" tabindex="6">
</fieldset>
</form>
</li>
</ul>
</div>
|
|
|
|
|
hi ,
dont go to action of other page. end part of code (php code) include in top of the form code(inside a php tag) .
dont put echo in that php part redirect to this page get a value from url
Example:
<title>
.... Your form code .......
Redirect example :
header("Location:text.php?val=Successfull message");
Thank You....
|
|
|
|
|
Hi,
I am using this to as header for my email form submition send.php file:
$mailheader = "From: ".$_POST["email"]."\r\n";
but I also have
$_POST["email"]
coming from the contact.php form.
I want to know how can I send the email but make sure to show the name and in the From like this Jassim Rahma <jassim@email.com> so the name will be shown in the inbox of the recipient's email instead of the email address
Thanks,
Jassim
|
|
|
|
|
To show the name in the from field, use this format:
From: My Name <address@domain-name.com>
So in your PHP you should put something like this:
$mailheader = "From: " . $_POST['name'] . " <" . $_POST['email'] . ">\r\n";
|
|
|
|
|
Hi all !!!
We use ResourceBundle to access properties in JAVA.
I want to know can we have .PROPERTIES file as like JAVA in PHP to access resources?
if yes then tell me how is it?
|
|
|
|
|
I am not sure about what you need
read about
1. include
2. include_once
3. require
4. require_once
5. eval
|
|
|
|
|
Thank you.
I studied on the topics you provided.
I think, Java uses properties files because Java code gets compiled into binary format and therefore making any code changes becomes difficult. By removing configuration values of a text file, Java enables people to change the configuration without recompiling.
PHP, on the other hand, is not compiled into binary. Therefore, the PHP files are always editable by a a plain text editor. Most PHP apps handle configuration options by placing them into a separate PHP file with lots of comments describing each setting. And the settings are directly made to variables. Then any PHP code that needs those settings includes that file and then uses the variables. For an example of this, look at the settings.php file that comes with Drupal.
|
|
|
|
|
The thing you thought about java is true,
It creates Binary code when you compile,
PHP compile every time someone request php
By the way I am confused, who asked the question?
|
|
|
|
|
Initially I was confused, but I studied the 5 points given by you.
After that I found the solution. The credit goes to you. You showed me direction.
|
|
|
|
|
I want to send SMS messages via SMPP and I want to know if anyone tried it? which SMPP control did you you use? which one you recommend?
|
|
|
|
|
Hi,
Hope this link will help you..
<a href="http://www.ozeki.hu/index.phtml?ow_page_number=142">http://www.ozeki.hu/index.phtml?ow_page_number=142</a>[<a href="http://www.ozeki.hu/index.phtml?ow_page_number=142" target="_blank" title="New Window">^</a>]
|
|
|
|
|
Have you tried implementing SMPP Client??
|
|
|
|
|
Hi all,
I am new to Cake PHP.
What is the difference between PHP and Cake PHP ?
Please anyone can tell me what is cake php and how to use it ?
And also can any provide me the examples for it.
Thanks in advance.
|
|
|
|
|
Hi,
Cake PHP is a framework for developing and deploying PHP appications.
Its like some other frameworks like Joomla, Symfony. You can find more
information here
http://cakephp.org
|
|
|
|
|
If by chance anyone might know what may be wrong... I tried installing Red Hat Enterprise 5.3 on one of my laptops with an SSD doing a clean install (wipe everything) but even though it goes through the whole installation process, it doesn't boot into Red Hat after the final reboot. It seems to either get stuck rebooting (power cycling) or get stuck in Grub with no option to boot into Red Hat. I installed Ubuntu 11.10 and Fedora 16 on that same set up with no problem (Ubuntu is on another drive but the Fedora installed fine on the SSD).
Right now I'm suspecting the DVD I'm using might have something wrong with it... I tried to make an iso of it to keep a copy on a server and the CRC checks kept failing, although when I tested the disk from the Red Hat prompt (at install time) it said the disk was fine.
Don't really know what else may be causing this issue.
|
|
|
|
|
I would say its a bad iso, can you re-download it?
|
|
|
|
|
Haven't had a chance to revisit this but I did download some new ISOs to try. Fedora worked fine on the very same set up.
|
|
|
|
|
Is there any body that has experience with qt in linux?
and qt in embedded linux?
for choosing qt frame work or developing with linux api without framework
thnx
|
|
|
|
|
|
I don't have a question
This is just a subject for discussion
|
|
|
|
|
This is not the place.
Unrequited desire is character building. OriginalGriff
I'm sitting here giving you a standing ovation - Len Goodman
|
|
|
|