Adding html form and input tags into Symfony static pages - symfony1

I inherited the management of a Symfony site and need to add some HTMl form tags to one of the "static" pages via the CMS. The scenario I have is:
/index.php/splash/welcome pulls up the welcome screen.
We want to be able to add a subscription button on that page.
The HTML has been supplied for us by the company that handles the subscriptions.
The form post method has an action that references a script on a remote site (no lectures on the security implications please ;-).
When I add the <form... and <input... tags via the CMS admin panel, the tags get removed automatically by Symfony.
Is there a way to tell Symfony to allow these tags?
Thanks in advance,
Marty.

This is goign to depend completely on how the developer set up the CMS. Youre using a rich text editor in source mode i would take a look at that editor's config file and documentation because its probably the one responsible for stripping the tags.
If its just a plain text area i would check the submit action for the edit form and take a look at the code... he may be using something to strip them in there.
If youre using one of the Symfony CMS plugins (Diem, Apostrophe, Sympal) i might be able to help further if i know which one youre using. If its something custom we would need to see the code. This isnt really indiciative of the Symfony core, but rather the CMS youre using.

Related

Google Website translator translates only single page in Rails

I'm trying to have a multi language website in rails.
So I added the google translate from here
I added the meta script to my application.html.erb so that my whole site is translated.
And the div to my index page only.
But it just translates the index page and not the whole site. When I open the links in the index page they don't get translated. I don't want to add that div to every page in my site.I read this stackoverflow sloution here but that is not working for me. Suggest a solution.
I'm also aware of the Rails I18n library for internationalization but I guess I need to write all the translations myself manually, which I don't want to do.
Can I18n be automated like Google translator?
Are there any alternatives to that which work in fine in Rails?
You have to add the Google translate plugin code to every page or to which ever page you want to make it work .

creating Entry form in Umbraco for Add/Edit/Delete/Search functions

This is repeatedly asked many times, however i couldn't find appropriate solution for my problem.
I want to create an Entry Form which will consists of following elements:
Text boxes, drop down fields (auto populated) , check boxes , radio buttons
After my research
i found that i need to create user control, or script file for above form and access it via Macro.
I don't want to use User control as my first preference is to controller-View-Model (i.e. cshtml)
I want to follow MVC approach to create above form. So
1) Do i need to create a seperate project for Add/Edit/Delete/Search Data Entry form?
2) OR i need to create cshtml file for the same(not so clear about this approach)
I'm looking this data entry form with easier for customization and i could use it in other applications as well.
From Umbraco 4.10 up to 6.0.x you can use MVC in Umbraco so there's no need to use an usercontrol. You probably want to use a SurfaceController where you can add any Action you want. The rest is standard MVC (Razor views to build your textboxes, drop downs, ...).
Check out the Umbraco MVC documentation where they explain how to use MVC in an Umbraco project.

asp mvc file upload

I have a form in asp.net mvc 3 project with some properties (a name and some extra properties who need to be filled in).
What i also need is a file to upload in the same form.
I placed an input type "file" and that works when i use Request.File the file is ok.
But i'm also using form validation, so when my name is not filled in, it's not possible to save. That works fine, but then my file is cleared..
Someone who has a good example to use file upload in a form? (with other fields and validation)
In addition to #Neil Knight's excellent references in his answer, if you're using ajax (and you probably are or will be to leverage MVC's ability to facilitate partial page refreshes) the jquery plugin here has proved itself useful in enabling file upload without a full page navigation.

How can I find where actually is the theme file?

I am new to Symfony and I need to work to a large project with many themes to modify them. How can I find where actually is the theme file in which module, just looking at the HTML browser output? Or do I need to look somewhere else, routing for example?
What you want to do is use the Web Debug Toolbar.
Once you have that running on the page, using appname_dev.php, simple click the view link and it will show you which templates have been used. If you need to know which layout to use then use logs link, click none the sfPHPView.

Looking for a page designer

My site currently has some static pages. I'm looking for a rails wysiwyg webtool with which I can change those static pages (with images) dynamically. The number of pages is fixed and I don't have to be able to dynamically add new.
Update
The site already has a design template assigned which I don't need to change. I only need to be able to change the content of some of the pages.
Someone can suggest me something?
Thanks
Stijn
Are you looking for a server site tool that facilitates editing static HTML files but uses a web browser interface?
If so I think that only solves part of the problem. You pages still have, presumably, some common "furniture" like a Banner pane, Left pane, Right pane, Footer. If you want to change these you will have to edit every file. What about if you have telephone number in the Banner - if that changed it would be better to just change that centrally.
These are problems that a Content Management System addresses, so if you are not familiar with that you may want to read up on CMS.
To compare CMS systems see: http://cmsmatrix.org/matrix/cms-matrix?func=search
You can enter "Rails" or maybe "Ruby" in the Language field of the Search form
Try Radiant CMS

Resources