This is a migrated thread and some comments may be shown as answers.

Open Navigate URL in new page

5 Answers 228 Views
TagCloud
This is a migrated thread and some comments may be shown as answers.
Hamed
Top achievements
Rank 1
Hamed asked on 02 Sep 2010, 03:28 AM
Hi guys,
I am new to programming and maybe my enquiries seem funny.
Currently I am using the RadTagCloud Control based on data binding in my prototype system.
Everything works great. I just want to open the resource related to each tag (which is stored in NavigareURL field) in a new window when I click each item in the TagCloud.
Any ideas?

Also, I have a textbox in my web page which I want to clear its content when I click on any tag in the tag cloud, but the RadTagCloud1_ItemClick is not fired to do this.
Any help here?

Cheers,
Hamed

5 Answers, 1 is accepted

Sort by
0
Georgi Tunev
Telerik team
answered on 03 Sep 2010, 02:17 PM
Hi Hamed,

Currently RadTagCloud does not support this out of the box (such feature will be present in Q3 2010), but it can easily be achieved with a few lines of code:

<script type="text/javascript">
    function OnClientLoad(sender, args)
    {
        var items = sender.get_items();
        for (var i = 0; i < items.length; i++)
        {
            items[i].get_anchorElement().setAttribute("target", "_blank");
        }
        }
</script>
 
<telerik:RadTagCloud ID="RadTagCloud1" OnClientLoad="OnClientLoad" Width="500" runat="server">
    <Items>
        <telerik:RadTagCloudItem Text="Item" NavigateUrl="http://google.com" />
        <telerik:RadTagCloudItem Text="Item" NavigateUrl="http://google.com" />
        <telerik:RadTagCloudItem Text="Item" NavigateUrl="http://google.com" />
        <telerik:RadTagCloudItem Text="Item" NavigateUrl="http://google.com" />
    </Items>
</telerik:RadTagCloud>

As for your second question, please make sure that AutoPostBack is set to true. If you still experience problems after that, it will be best to open a support ticket and to send us a sample project so we can get a better view over your exact scenario.


Greetings,
Georgi Tunev
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Hamed
Top achievements
Rank 1
answered on 08 Sep 2010, 07:08 AM
Hi Georgi

Thank you very much for your great help.
The first issue was solved.
About the second one:
Imagine that I have a RadTagCloud in page1.aspx and I have a panel control in page2.aspx (page 2 is shown after clicking items in RadTagCloud).
I need to make the panel control "invisible" in page2 when I click on any item of RadTagCloud in page1.
I don't know how to do this.

Cheers,
Hamed
0
Accepted
Pero
Telerik team
answered on 10 Sep 2010, 01:39 PM
Hello Hamed,

I believe the following article from MSDN will be helpful: http://msdn.microsoft.com/en-us/library/ms178139.aspx.

Kind regards,
Pero
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Carsten Koster
Top achievements
Rank 2
answered on 11 Jun 2012, 07:43 AM
Hello telerik team,

is this feature (opening a new Window onclick by setting a serverside variable) now implemented?
I could not find anything in the serverside documentation.

Thank you for your help!

Regards
0
Slav
Telerik team
answered on 13 Jun 2012, 12:43 PM
Hello Carsten,

You can set the RadTagCloud property Target to _blank in order to open the item's link in a new window or tab. This property is used for specifiing the target window or frame to display the new content when a RadTagCloud item is clicked:
<telerik:RadTagCloud runat="server" ID="RadTagCloud1" Target="_blank">
...
</telerik:RadTagCloud>

Truly, the Target property is missing from the Server-Side API documentation of RadTagCloud. Thank you for bringing this to out attention, the help article will be updated accordingly.

All the best,
Slav
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
Tags
TagCloud
Asked by
Hamed
Top achievements
Rank 1
Answers by
Georgi Tunev
Telerik team
Hamed
Top achievements
Rank 1
Pero
Telerik team
Carsten Koster
Top achievements
Rank 2
Slav
Telerik team
Share this question
or