Asp.net ajax control toolkit html editor content disappears - asp.net

I am doing a design screen for my customers and i use jquery sortable portlets.
i put the html editor each column.When u write something into the editor then drag drop the portlets the editor's content is disappearing.After droping it,i change the active mode of editor to preview and design,then i see that content is there.How can i solve this problem ?

I play now a little with the jquery sortable portlets and I notice that its not just move the position of each div, but redesign the full struct of the divs on each drag-drop.
This is mean that is probably copy/paste the inside div on every moving action.
Now your editor is initialize what its show, and from the moment that the portless is move the div content to other possition, the initialize from the editor is lost.
To gain it again I suggest to reinitialize the editor after any drag-drop.

Related

Wordpress editor: lock editing part of page

My client wants to edit pages content in Wordpress. I had to disable visual editor because it ruins custom html. The problem is my client isn't familiar with HTML.
What I want is to lock part of source code in WP editor for ex. in line
<div class="whatever">Lorem ipsum</div>
I want to allow him to modify only "Lorem ipsum" part.
How can I do that?
well you can provide a textarea for him to enter text and then replace html inside element with class whatever, so basically you control regions of html where modifications can be made instead of whole page, of-course you need to write some code to do so.
I would simply mark the editable regions with some kinda class, and then on page load add some script which will pick all regions with that clas and show a small editable button there, on click of those button a shim with text area would pop up where user can add his text/html and on done, the markup would be injected inside the element. Later on save, the whole page would can be saved, little tricky but can work :)

Colorbox inside iFrame - Close from parent

I am working on a project where I am simply loading same directory content into an iFrame. No external pages.
I have Colorbox within the iFrame content which is working beautifully.
My question is: I have some "parent" buttons which I would like to make them close any of the iFrame Colorbox popups. The project is an "information point" system with some buttons in the parent that show at all times, but whenever I click the buttons the iFrame Colorbox stays open.
A lot of the pages I have found talk from the opposite way, controlling the parent from within a Colorbox iFrame...
I'm going to guess that this may not be achievable from a security point of view...
many thanks everyone :)
You might be able to do something like this:
$('.cboxIframe')[0].contentWindow().$.colorbox.close();
I ended up using jQuery the other way round so the child controls the parent and hides the parent controls and when the ColorBox control is closed it "shows" the parent controls.

add hover to asp.net menu control

i have a image menu within my asp.net website. i want to include an easy solution for hoverover functionality. for example, menu item one would dispay 1.jpg on page load and hover1.jpg when a user hovers their mouse over the image. thanks for any support.
You can do this easily via javascript :
http://www.webdevelopersnotes.com/tutorials/javascript/javascript_image_change_functions.php3

Setting Busy cursor for the html page with iframes having flex applications

I have a html page with 4 iframes out of these 4 one is a static html page and other 3 are html generated by flex. I have a button and list in one of the flex applications and the list will be populated on click of the button. Now what I want is to have a custom busy cursor to appear on the top of the whole html page until the list gets populated.
Please tell me if its possible with an example.
Thanks in advance
Prahsant Dubey
OK, you can not have flex control the cursor over areas of the page not part of the flash player. But here's what you can do. Call external javascript from flex, then use JS to do the cursor.
Here's how to call JS from flex:
http://www.switchonthecode.com/tutorials/flex-javascript-basics-using-externalinterface
and here's how to do a JS cursor:
http://www.webcodingtech.com/javascript/change-cursor.php

ASP Menu bar, Static view

I am looking to create a menu bar with a specic type of "action"
Similar to the bar on this website
BBC Sport
Its totally static and has no dynamic or "pop out" sections. When the top menu is clicked the page will re-load and display the lower level in a diffrent colour.
Can this be achived with the Standard ASP:Menu control?
I am not a big fan of the pop out feature however I do not want all my options to be visible to my users at root
Hope that makes sense
Check out this basic ASP.Net Menu control page. You can click on the "Run" buttons to see very basic versions of the menus.
The advantage of using this particular approach is that you can tie it to a sitemap, so you don't have to keep updating the menu code. You just add the page(s) to the sitemap, and the menu picks it up.
You can also dynamically link the menu to different sitemaps, such as one for the admin menu and another for regular users' menu.
The Menu control is in the navigation section of the toolbox.
To experiment with the built-in functionality (before writing your own code to do what it will do for you), just drag and drop a menu control onto your form. Then, use the common tasks menu to:
autoformat -- good for quick & dirty because it sets hoverstyle too
set the data source
set the view type (static or dynamic)
define menu items with an editor
work with templates to set appearance
You have to go to properties to set menu appearance.

Resources