how to block http requests to some web-pages from adobe air - apache-flex

Is it any way to prevent user to go to specific web-pages using Adobe AIR framework.
I want this software to run at startup and not allowing user to surf some web parts.
I want to use Adobe AIR beacause of its crossplatform capabilities.

While AIR can detect the computer's connectivity status, it does not come with the ability to restrict access by other applications.

Related

Asp.net application for voice calls

I have a requirement for web application developed in asp.net which allows users to make voice calls among each other from the website.
I have looked at api of skype but it seems more inclined towards desktop application. IS there any api which supports for web application like gtalk etc.
Which technology could be best used for developing such kind of applications? Any input, references would be helpful.
I did read that jabber is underlying technology for gtalk. Does jabber support voice calls, and would it be useful for my situation?
If you can include Flash, it has API for that job, but for client side layer only... probably you can chose java/.net for server side.
The only solution here is flash. Gmail / Gtalk requires the user to download a plugin for it to work, so technically it is a windows application being called from a webpage.
I recommend flash and asp.net for the backend, as said above. Either that or if you are OK with deploying plugins, you could go that route. I wouldn't recommend it unless it is internal only.

What is the best architecture for building a .NET website that may also support a native mobile app in the future?

I am in the planning phases of building a new ASP.NET website. The website is really a transactional web application where the users will log in and perform basic CRUD data operations. For right now this website will be accessible through a traditional desktop browser and a mobile browser. For the mobile browser we will build a separate scaled down version of the site.
In the future we may decide to create native mobile applications for Android or iOS devices also.
So the question I have is what is the best way to design the system to easily support that? Here is what I am thinking. I am thinking of building out 3 tiers to the site. The back end will be the database - SQL Server 2008. We will use stored procedures for all data access. The middle tier will be a web services tier. This tier will be built using RESTful web services and will contain all of the business logic. These web services will provide access to the database. The front end will be built using ASP.NET. The front end will only contain presentation logic. These tiers will actually be deployed on physically separate servers.
Then I am thinking that when we decide to build a native Android or iOS app that we could build those apps to simply call the same RESTful web services that the main site is calling.
Does this seem like a reasonable approach? The only thing I can think of is that the way we are building it right now the web services would be behind the firewall and would not be accessible to the outside world. When we want to support a native mobile app then we would need to make the web services accessible to the outside world.
Any thoughts? Does this seem like a good approach for building a high availability, high usage web app that needs to support native mobile apps in the future?
Thanks,
Corey
I'm with Rober Harvey there. With ASP.NET MVC you can make the presentation site in no time, use as Models your web service; with the link that he gave you, set the site for mobile browsing, and use the web services for the mobile apps when you build them.
For me it looks like a good plan. Regarding the web services being public, you can protect yourself by implementing API keys in the web service, so only your apps can use it.

Can WPF browser apps be used as a replacement for ASP.NET?

I don't understand the purpose of the WPF browser appliction. Is it simply another way of serving information through a browser, or is it not intended to be used for external deployment?
WPF Browser applications allow you to create very rich, application style UI's deployable via the web, using coding languages windows developers already likely have in their toolset. The downsides are that the users must must have .net installed, and use IE to access the application, considerably limiting the size and scope of your audience. WPF browser applications are very similar to Java applications in that they run in a virtual machine on the client. As it runs on the client, all data access and communication with the server must be done through WCF or web services.
With ASP.NET you have considerably more cross browser compatibility and support, giving you access to a much larger audience, with the possible downside of learning new libraries and the ASP.NET programming model. ASP.NET also provides a rich data access model and data control support. Silverlight is another interesting option based on .NET and WPF, as it is supported by a wide variety of browsers and provides similar rich user interface experiences. It can als be run out of the browser, disconnected if neccesary.
** Update based on Comment Request ***
The big advantage to Silverlight out of browser, is that you get most of the Rich, windows application style functionality, with a web deployable model and tiny install (4-6MB). Silverlight also supports an auto update feature which is VERY nice if you have a large user base.
Microsoft's Official description (propaganda :) )here
Silverlight Out Of Browser
Enables users to place their favorite Silverlight applications directly onto their PC and Mac, with links on the desktop and start menu—all without the need to download an additional runtime or browser plug-in. Further, the new experience enables Silverlight applications to work whether the computer is connected to the Internet or not—a radical improvement to the traditional Web experience. Features include:
Safe and secure. Leveraging the security features of the .NET Framework, Silverlight applications run inside a secure sandbox with persistent isolated storage. These applications have most of the same security restrictions as traditional web apps and so can be trusted without security warnings or prompts, minimizing user interruptions.
Smooth installation. Because Silverlight applications are stored in a local cache and do not require extra privileges to run, the installation process is quick and efficient.
Auto-update. Upon launch, Silverlight applications can check for new versions on the server, and automatically update if one is found.
Internet connectivity detection. Silverlight applications can now detect whether they have Internet connectivity and can react intelligently including caching a users’ data until their connection is restored.
A WPF browser application is a client side technology, rather than ASP(.NET) which is server-side. It is definitely not meant to replace it.
Using a WPF browser application one can provide a rich client inside the browser. However, this will only work when the whole .NET framework is installed. Another similar technology is Silverlight, which uses a very small (the installer about 5-6 MiB) framework, and is available to multiple platforms. It includes a small subset of .NET framework.
You can use it in external deployment considering the above requirements.
The following portion of the above selected comment is wrong:
and use IE to access the application,
considerably limiting the size and
scope of your audience
WPF in the browser (aka XBAP) is works just from FireFox (Mozilla) and Google Chrome. It was true about 2 years ago, but not today.
You could use XAML in silverlight, if thats what you are looking for.
Plus the RIA Application templates makes development quite neat.

which is better for desktop application?

i'm new to creating desktop applications. I've a working site in php with mysql support. I want to convert this site into a desktop application. Is Adobe AIR or Adobe Flex better?
can i use php as such in both AIR and Flex? or should i convert them to xml or something which it uses?
AIR is Flex on the desktop... So... I suppose you mean whether you can use AIR with PHP? AIR/Flex should be able to handle whatever communication protocol you're using on the server.
Saying 'should i convert them to xml or something' is a bit nebulous.
I guess what you really asking is: Should I rewrite my application entirely in Adobe technologies or Can I/Should I integrate it with my existing PHP code.
I would recommend you expose the existing PHP functionality as RESTful web services and redo the user interface in Adobe AIR. That way you can leverage the existing site to make the desktop application. There is a ton of information of building applications like this, just research REST, SOA (service oriented architecture), SAAS (Software as a Service).
Adobe AIR/Flex is fine, especially if you want it to work on multiple operating systems, but the Application won't necessary have the looking and feel of its host desktop environment.
Adobe AIR is a runtime that adds to the capabilities of Adobe Flash Player to allow the creation of desktop applications.
Adobe Flex is a framework to build rich user interfaces. Flex applications are supported both in Flash Player and AIR.
This cannot be a question of one or the other. Flex can be used together with AIR. If you want a desktop app that allows you to use Adobe's Flash Platform technologies, definitely use AIR. If you want a set of pre-built UI controls to use in that AIR app, use Flex too!
You can communicate with PHP on your server in both Flash Player and AIR. PHP cannot be run directly in AIR. If you want the application to be entirely self-contained with no server, then you can't use PHP.

Can I host an ASP.NET application in a CAB WinForms application?

I have a .NET 2.0 WinForms application that was developed using the Composite Application Block and Smart Client Software Factory.
I'm considering the development of a module that would contain a browser control that would access the ASP.NET website using credentials established when the user logged into the WinForms client.
My goal is to use this strategy to transition all of the modules that are currently in the client to ASP.NET and retire the 'smart' client. Security for the WinForms client is currently implemented using the ASP.NET Membership functionality.
Is this possible? Sensible?
Yes, you can. Make a SmartPart that hosts the WebBrowser control, add some buttons for forward and backward navigation, and a url textbox; then point the WebBrowser control at your web application's URL.
It is sensible. We used CAB/SCSF to create an application we called "The Integrated Desktop". This application serves as the platform for all internal apps for the company; everything is integrated into this one desktop application. We added a foundational module, basically a beefy version of what I described in the above paragraph, to facilitate web browsing since a few pre-existing apps were web-based and our users wanted access to those at the same place they were doing all their other work. One cool thing was the use of the WebBrowser's ObjectForScripting property that allowed for somewhat seamless integration between the desktop app and the web app being hosted inside.
What are your requirements?
You would choose a web app over a smart client mainly
if you have to reach people that
are not on the Windows platform or
you have a need for a
zero-install app
By having your app users having to access the web app via the smart client (browser-control) you would be missing (1) and (2). In my opinion it would defeat its purpose.

Resources