On live server how can i create aspnet_roles - asp.net-mvc-3

I posted my asp.net website on MVC3 live on godaddy server. How can i create admin role and add users to it? Is there an easy way to do this? Even if through sqlserver please respond with some level of code to understand better. Thanks!

Create it in your local database and push that up to your site in app_data.
You should be able to click the small icon at the top of solution explorer to admin your site and create the roles. No code required.

If you have already populated SQL database by copying the database to GoDaddy Server, you can use these stored procedures already present in it.
To create an admin role
EXEC #return_value = [dbo].[aspnet_Roles_CreateRole]
#ApplicationName = N'/',
#RoleName = N'admin'
To add users to the role execute the stored procedure aspnet_UsersInRoles_AddUsersToRoles. Please be sure to create the user by executing aspnet_Users_CreateUser if there ain't already a user.

Related

Database system in website builder such as Wix or Squarespace

Are you familiar with website builder?
There are bunch of website builder companies such as wix, squarespace, duda, odoo,shopify, weebly...
Here, when we create account first, they assign subdomain of their website.
For instance, companyname.shopifyapp.com, xxx.squarespace.com
I think there are over 1 million customers for some websites.
Can anyone tell about database system of those websites?
If new customer signup and get his website, then will they save all his data in one big db including website template, setting and so on ?
I think if then, we can identify all data by subdomain or user id in one db.
Or they will generate code and database dynamically for each user?
Thanks.

How to run magento files on local server?

I have done one work which is stored in the webserver. I downloaded all the files and the database and uploaded onto the local server.When I am typing the local server url ,its going to the web server url.Also when i am logging onto the admin panel in magento in local server, its going to the admin panel in the webserver.How can it be corrected ? Actually I am new to Magento.
You should have to update base url in your database. Open your phpmyadmin, go to core_config_data and update your new url. Use below mysql query,
UPDATE core_config_data SET value="http://localhost/your-magento-location" WHERE path='web/unsecure/host';
Don't forget to clear cache.
Note: Please consider that, before ask question here, you should have search in google. If you are not able to find answer, then you can ask
here.

phpMyAdmin has two database tables under one heading

I am in the process of moving my local website onto a live webhost and am having some confusion while exporting my database tables from phpMyAdmin.
I attached a screenshot for reference.
It seems as if there are two database tables that are being used for my website, I'm not sure how this happened though. What I am trying to figure out is which database table is the one that I need to export along with all my Joomla files?
I went into my htdocs to check the configuration.php file and it says that the database prefix is xxx (i made this up) BUT when I go look into that database table (on phpMyAdmin) the dates of creation don't match up but are current in the "other database table."
Thank you for your help.
Screenshot for reference
To ascertain which is the correct database, create a new user via the Joomla interface, then have a look at the users Joomla table via phpMyAdmin, in both databases, to see in which database the user got created.
This information can be found in your site's admin at Site => Global Configuration => Server

Joomla front end has no content after web server move

I am so stumped with this and I need some help from the community. I moved my joomla site over to a new server and now the content has disappeared from the front end, I am not getting an errors.... Can someone offer any suggestions on where to look for the problem? my config is fine and I am pretty sure my database is aswell because all my original articles are there.
I am running Joomla 1.5
The URL: http://www.davidjamesmedia.ca
If you moved to a new server at a different hosting company, Joomla is probably either
not looking in the right place for the database, or
not using the right credentials (host, port, username, password, whatever) for the database.
That might also be true if you moved to a different server at the same hosting company, although it's a little less likely. Look at the configuration.php file.
Assuming you have shell access, make sure you can access the database through its command-line utility. Then make sure Joomla is using the same credentials.
This is a really odd one.
The database credentials are obviously correct otherwise the site wouldn't load at all and would result in a MySQL error. Try re-assigning a new temporary article to the homepage else download the K2 component, import your articles and assign the K2 article to the homepage.
Update:
If you have the demo package for the template you are using the follow these steps:
create a sub domain
install the demo package with sample data
export the #__content database table from the main website
replace the #__content table with the one you exported
Make sure your error reporting is on in your server's php.ini file so that you can see what errors php is giving i.e. error_reporting = E_ALL & ~E_DEPRECATED
In admin panel, can you see the articles in content menu?
If so, enter in each article and push the Save button.
After you save the article, it should appear again in frontpage (that worked for me).

Joomla ACL: Only allow access to custom component in the backend?

I'm building a component for the backend. I don't want the users who will access it to access ANYTHING else in the backend except for this component.
I tried following these two instructions:
http://www.aclmanager.net/blog/general/31-how-to-add-basic-acl-support-to-your-extension
http://docs.joomla.org/Developing_a_Model-View-Controller_%28MVC%29_Component_for_Joomla!1.6_-_Part_14#Describing_the_ACL
I made a new User Group with a parent of public and allow admin login (which would lock them out of everything) and then tried adding the ACL code from those links above with permissions to create and edit but I just get a blank screen (not even a logout link). The "Debug Permissions Report" showed the correct permissions but nothing's showing up.
Any ideas? My next step is to manually go through every component and not allow access to that new User Group but it seems like there's an easier way.
Thanks!
In Joomla! 2.5 we regularly create "Content" only backend users that have access only to the 'com_content' component.
Going back through our steps the only thing you haven't specified is adding the new user group to a View Access Level. If you're using the standard sample content installed when setting up a Joomla! website you can add your new user group to the "Special" view access (although any will do).
If a new group has 'admin login' privileges it can login but without a View Access level it can't see anything.. it's a subtle difference but it's the way Joomla! works.

Resources