Jump to content

Quotation Mark


eMac
 Share

Recommended Posts

I am creating a small step-by-step wizard. I created a edit box, within this edit box I want to display the CODE a user should copy/paste into their website for the mod to work. Problem is, my code is quotation marks within it and Autoit sees these as the end of the edit field, is there a way to show the quotation mark by using a special symbol so it ignores that quotation mark and prints it in the edit box?

Codename: Source ProgrammerWhat Is Codename: Source? A community designed operating system based off of the Windows OS. Source brings the ideas of the community to life as each user brings his or her own ideas into the development of this project.
Link to comment
Share on other sites

I am creating a small step-by-step wizard. I created a edit box, within this edit box I want to display the CODE a user should copy/paste into their website for the mod to work. Problem is, my code is quotation marks within it and Autoit sees these as the end of the edit field, is there a way to show the quotation mark by using a special symbol so it ignores that quotation mark and prints it in the edit box?

Not sure I totally understand here. Are you trying to convert plain text to HTML?

George

Question about decompiling code? Read the decompiling FAQ and don't bother posting the question in the forums.

Be sure to read and follow the forum rules. -AKA the AutoIt Reading and Comprehension Skills test.***

The PCRE (Regular Expression) ToolKit for AutoIT - (Updated Oct 20, 2011 ver:3.0.1.13) - Please update your current version before filing any bug reports. The installer now includes both 32 and 64 bit versions. No change in version number.

Visit my Blog .. currently not active but it will soon be resplendent with news and views. Also please remove any links you may have to my website. it is soon to be closed and replaced with something else.

"Old age and treachery will always overcome youth and skill!"

Link to comment
Share on other sites

Not sure I totally understand here. Are you trying to convert plain text to HTML?

No, heres a demo, think of it has a GUI version of a readme.txt, where my .exe autoit script gives step-by-step instructions on how to add a mod to their site.

$ChildGui_3 = GuiCreate("Functions", 400, 260, 5, 5, $WS_POPUP)
$step2 = GuiCtrlCreateLabel("Step 2 - Functions", 0, 70, 380, 60)
$step2_1 = GuiCtrlCreateLabel("Within your FTP, open '/modules/member.php' and copy/paste the following code at the very bottom of this file right before ?>", 0, 110, 380, 60)
$step2_2 = GUICtrlCreateEdit("function my_mood(){" & @CRLF "$info = $GLOBALS["Member"]->info();", 0, 140, 380, 100)

GUICtrlSetFont($step2, 9, 800, "", "Arial")
GUICtrlSetFont($step2_1, 9, 400, "", "Arial")

If you notice line 4 of that code I posted, I have "$info = $GLOBALS["Members"]

Well, Autoit sees the " " next to Members as the end of the GuiCtrlCreateEdit, therefore, stopping it.

Can I somehow make autoit ignore these two "" and not stop the line into the final " at the end of the code?

Basically, it's just the code that will appear in an edit box, they can selectall / copy, and paste into their actual .php file.

Codename: Source ProgrammerWhat Is Codename: Source? A community designed operating system based off of the Windows OS. Source brings the ideas of the community to life as each user brings his or her own ideas into the development of this project.
Link to comment
Share on other sites

Easiest way is use single quotes (apostrophes) or double the quotes. Two examples here:

$string = "He said, ""I don't know,"" while shrugging his shoulders."

Or

$string = 'He said, "I don''t know," while shrugging his shoulders.' ; Note the doubled single quote in "don't"

Thank you, solution #1 with double quotes worked great.

Codename: Source ProgrammerWhat Is Codename: Source? A community designed operating system based off of the Windows OS. Source brings the ideas of the community to life as each user brings his or her own ideas into the development of this project.
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...