Asp.net webparts or portlet like functionality - c#

What is the best way to let other parties use your website as their own content using their own style ?
We have build a small website for a customer, asp.net, .net framework 3.0. Now the customer wants other parties to be aple to use our website in their own websites while maintaining the styling of the costumers website.
I have done nothing like this before and don't even know what to google, so any help is appriciated.
I know you can do this with sharepoint, but to use sharepoint for such a small site seems like a lot of overkill
it sounds that portlets is a good name for what they want. but googling portlets draws me in the world of java and doesn't give me a lot of info on what the other parties would have to do to make it work.
a simple Iframe would probably take me a long way, but how can you get the styling done within an Iframe
webparts also sound interesting , but they seem more for in project sharing then letting people use them in their own site.
It is a small website and the logic and backend communication is pretty good contained, so a complete rework of the frond-end is not a big problem.
Once again, any help is appreciated !

Omar Al Zabir has a book on how to build a Portal in ASP.NET- here is a link to his Website.
You might want to look at his Dropthings portal.

Yes, portlets are pretty much Java-only, despite any talk of standards.
If you can encapsulate your pages in web parts or user controls, that would make it easy to style them, and even to parameterize them: a web part can be configured.

You can use Kalitte Dynamic Dashboards for creating professional dashboards and portlets.
More information can be found at www.dynamicdashboards.net

Related

Help with getting started building an ASP.NET website using VS2010

Ok, I want to build a web site using ASP.Net. My web development skills are very small. However I have used C# a fair bit for some fairly intermediate level work (lists, dictionaries, custom classes etc)
The site I want to build will run on an intranet, and I'll be using the AD to get the current users information.
This information will be cross checked with an MS SQL 2008 database (that already exists on the network) to determine what links they can see.
Other parts of the site will allow the User Table to be viewed and modified if the current user is an admin, and have new users added.
So, what is the best way to do this? I've done some playing and basically confused myself with all the options available..
For example, I can create a New Project, which gives me options like Web Application, MVC2 Web App, MVC3 Web App, Empty Web App, Dynamic Data Entities Web App, Data Linq to SQL Web App, and then some Server controls.
But then I can also go for the New Web Site, which has Web Site, Web Site (Razor), Empty Web Site, Dynamic Data Entities Web Site, Dynamic Data Linq Web Site..
There are too many options!?!?!? And I don't understand what the difference is between them all..
What do people suggest I use?
Have you tried following some of the MSDN Beginner Developer Learning Center stuff? They have a module on Beginning Website Development.
May be I am not answering to the point, but my 2cents. Why don't you go for Sharepoint development in this case. You can use Sharepoint site (having inbuilt AD support too) and develop custom webparts (like the part which queries SQL Server 2008). The advantage of using this is that you can merge the feature in intranet site (if you got one already using Sharepoint), and you can learn new stuffs too. Even it will be quick one and if in future, you want to use the Intranet site for different things, it's easily extensible with minimal fuss.
There are some good tutorials for MVC here http://www.asp.net/mvc.
I suggest if you are building a web site to use MVC as it seems like the latest and greatest from MS at this time. My personal opinion tho.
You would want to just start with New Project.
Ok, this is a lot of things to look at and there a are a few ways to tackle this. First all all just stick to New Web Site for now.
First things is to know if this is an intranet or internet?
it seems like it since you want to use AD, that it is an internal app.
Although there are many ways to accomplish what you are trying to do. I Think the following would be the easiest to implement.
1) Enable digest authentication
2) Set a IE group policy to the User authentication policy to Automatically logon only to intranet - This way people dont get confused to what they enter.
3) Create groups for each type of user in AD
4) Separate each functionality into different folders.
5) Set the web.config for permissons to the appororiate directories.
#Matt provided a link to a useful video ("Choosing the right programming model"). In it, Microsoft's Scott Hanselman describes the distinguishing characteristics of the three primary ASP paths: ASP.NET Web Forms, ASP.NET MVC, or ASP.NET Web Pages. Here's the main bullet points from that presentation:
ASP.NET Web Forms:
Familiar control- and event-based programming model
Controls encapsulate HTML, JS and CSS
Rich UI controls included - datagrids, charts, AJAX (common tasks available out-of-the-box)
Browser differences handled for you
SharePoint builds on Web Forms (so, useful if you want to be a SharePoint dev)
ASP.NET MVC:
Feels comfortable for many traditional web developers
Total control of HTML markup (controls not provided; good grasp of HTML required)
Supports Unit testing, TDD and Agile methodologies
Encourages more prescriptive applications
Extremely flexible and extensible
ASP.NET Web Pages:
Easy to pick up and learn (similar to PHP or classic ASP)
Inline scripting model with Razor and C# or VB.NET
Simplified model with Top-to-bottom execution
Full control over your HTML
Friendly Helper syntax (encapsulated functionality, similar to Web Forms controls) makes extending your apps easy
All these models are built on common ASP libraries, so there is considerable overlap, and a fairly straightforward path to migrate an app from one model to another.

Access to Facebook?

As a little learning project, I'd like to make a little app that reads data from a facebook users status updates. It's been done millions of times before, I'm sure, but is there an API or something? Would I need to signup for some Facebook developers license or anything, or is it as easy as finding the API, and then simply coding to it?
I'd like to simply get friends Status Updates via my login... seems easy enough. :)
The Facebook Developer links posted above are good, but it might be useful to look at some examples.
The Facebook C# SDK, found here: http://facebooksdk.codeplex.com/, has samples in ASP.NET MVC. It's a pretty simple project, so it should be relatively easy to see how things work in practice.
You can create an app at http://developers.facebook.com/
Then, download the sample project, replace the AppId and AppSecret with values from your registered app, and see how it works.
You can start reading here: http://developers.facebook.com/docs/
And look in the forum discussions here: http://forum.developers.facebook.net/index.php
This post was helpful to me http://gathadams.com/2007/06/18/how-to-write-a-facebook-application-in-10-minutes/
Also keep in mind this last change made for FB team about Post for canvas http://developers.facebook.com/docs/canvas/post/
Good luck!

Architecture of a CMS

I am building a custom Content Management System for my client, using C#2008, ASP.Net technology. I am looking for advice regarding the architecture (application layout, database layout etc) of such a system.
Anyone here have any experience design / developing such a system? Any websites that I can get more information from?
Any open source CMS out there?
Thanks in advance.
Any open source CMS out there?
Check out Umbraco, its very good, not suitable for everything (depends on your sites content really) but you get so much for free that it would be silly to not give it a look over, its not a small bedroom hack up job.
Regarding creating your own CMS, I'd probably try to steer you away from it, its not for the faint of heart unless your content demands are very niche. Even then its better to build on top of something else if at all possible.
ASP.net MVC would be worth a look too if you are going down that code your own route, would save you some headaches.
DotNetNuke is a good open source CMS is specifically for ASP.NET development. Definitely worth a look.
I've written a blog post about content modeling and data stores for content management systems. I think it could be useful: Blog post: Get more out of your content: content modeling and data stores

scraping/simulate browsing help

I want to make a program that will simulate a user browsing a site and clicking on links. Cookies and javascript have to be enabled. I've successfully done this in python, but I want to write it an compilable language (python ide's don't cut it). The links on the site are generated with javascript and are dynamic. With python I used PAMIE (third party module that uses win32com) to launch an instance of Internet explorer, scrape the generated html for the links, then navigate to one of them. The point is for the whole process to be transparent to the server. What's the best (compilable) language and method to do this? I was thinking C# with WebBrowser control but I don't want to spend a lot of time learning something if it isn't going to work. Any kind help is appreciated!
You might want to look at the automated testing via browser suites:
http://www.teknologika.com/blog/the-holy-grail-net-automated-web-gui-testing-for-internet-explorer/
http://watin.sourceforge.net/
I wrote a blog post on this awhile back: Web scraping in .NET. That discusses cookies but not JavaScript; I don't know if that would require additional coding.
Might be worth having a look at selenium .
We use it for web testing in a C# asp.net envirnorment.
The documentation isn't to bad

Using FLASH with ASP.NET - YAY or NAY?

I know i can use AJAX and SILVERLIGHT with my ASP.NET web page. But what do you think about using flash with asp.net? Can this be done? How can this be done? Would you recommend me using flash at all with ASP.NET? I will NOT be using WEB SERVICES, just a plain ASP.NET website.
Thanks in advance!
EDIT: What about performance issues???
I have used Flash in ASP.NET websites plenty.
Software should always boil down to the best tool for the job, if Flash is the way you need to go for your RIA, then so be it.
Remember, ASP.NET is nothing "new/different" ultimately, it is just a fancy HTML generator.
Therefore, to use flash, you simply use the plain old HTML OBJECT and EMBED tags to place the Flash on the page.
The benefit of using things like ASP.NET (or any other framework) is that you can encapsulate the EMBED logic to use things like swfObject.
flash is client side, what you use server side has very little impact on it.
Given Flash's high market penetration (98%+), I think Flash is a great way to go regardless of the underlying platform.
But, as with everything, it depends on what you want to do. If you want to deliver a rich user interface via Flash, you should consider using Flex.
There are several tools to help integrate a Flash/Flex application with ASP.NET. One of these that I recommend is WebORB.
It certainly can be done! We've done entire flash-based websites in the past that rely on data generated by a CMS and read from flash via XML. There are of course lots of gotchas (loading html text, multilingual characters), but once you've done it a few times you'll get the hang of it.
Flex is probably a better option.

Categories