Search Results

Search found 337 results on 14 pages for 'ankit sharma'.

Page 7/14 | < Previous Page | 3 4 5 6 7 8 9 10 11 12 13 14  | Next Page >

  • Django-modpython project in a directory

    - by Ankit Jaiswal
    Hi All, I am deploying a Django project on apache server with mod_python in linux. I have created a directory structure like: /var/www/html/django/demoInstall where demoInstall is my project. In the httpd.conf I have put the following code. <Location "/django/demoInstall"> SetHandler python-program PythonHandler django.core.handlers.modpython SetEnv DJANGO_SETTINGS_MODULE demoInstall.settings PythonOption django.root django/demoInstall PythonDebug On PythonPath "['/var/www/html/django'] + sys.path" </Location> It is getting me the django environment but the issue is that the urls mentioned in urls.py are not working correctly. In my url file I have mentioned the url like: (r'^$', views.index), Now, in the browser I am putting the url like : http://domainname/django/demoInstall/ and I am expecting the views.index to be invoked. But I guess it is expecting the url to be only: http://domainname/ . When I change the url mapping to: (r'^django/demoInstall$', views.index), it works fine. Please suggest as I do not want to change all the mappings in url config file. Thanks in advance.

    Read the article

  • What are your recommended tools and frameworks for network development on Linux?

    - by Vivek Sharma
    What are your favourite network-tools, which you use to troubleshoot or design (as in conceptualize) your network-application code. Ethereal/Wireshark Nmap any particular simulators (e.g. ns) any special purpose sniffer any particular frameworks, (e.g. iptables) I am looking at must have, and good/advantage to have tools/framework in ones profile/skill set. I think Wireshark and Nmap are must haves.

    Read the article

  • How to make Processes Run Parallel in Erlang?

    - by Ankit S
    Hello, startTrains() -> TotalDist = 100, Trains = [trainA,trainB ], PID = spawn(fun() -> train(1,length(Trains)) end), [ PID ! {self(),TrainData,TotalDist} || TrainData <- Trains], receive {_From, Mesg} -> error_logger:info_msg("~n Mesg ~p ~n",[Mesg]) after 10500 -> refresh end. so, I created Two Processes named trainA, trainB. I want to increment these process by 5 till it gets 100. I made different processes to make each of the train (process) increments its position parallely. But I was surprised to get the output sequentially i.e process trainA ends then process trainB starts. But I want to increment themselves at simultaneously. I want to run processes like this trainA 10 trainB 0 trainA 15 trainB 5 .... trainA 100 trainB 100 but I m getting trainA 0 .... trainA 90 trainA 95 trainA 100 trainA ends trainB 0 trainB 5 trainB 10 ..... trainB 100 How to make the processes run parallel/simultaneously? Hope you get my Q's. Please help me.

    Read the article

  • Sencha Touch Nestedlist JSON format Example

    - by Ankit Shah
    Hello Friends, I'm new to sencha. Using Sencha touch. I would like to make nested listing like first of list comes, when click on one of the link it goes to another listing, when click on second list's any link it opens image like that. http://dev.sencha.com/deploy/touch/examples/nestedlist/ Above example is perfectly suitable for this one more than that below application. http://touchstyle.mobi/app/ When i'm doing any modification in http://dev.sencha.com/deploy/touch/examples/nestedlist/ it gives no error or warning i'm using Fedora 11 linux Google Chrome. Can anybody tell me what is the JSON perfect format for this nested listing. I will do it for dynamic. So if anyone help to get static nested list it would be better.

    Read the article

  • Unable to checkout log4j repository

    - by ankit
    I'm using tortoiseSVN to checkout the log4j v1.2 source from - http://svn.apache.org/repos/asf/logging/log4j/trunk But i keep getting this error: Error: OPTIONS of '': Could not Error: resolve hostname `svn.apache.org': No such host is known. The funny thing is that i can access 'svn.apache.org' from my browser but if i try to ping it from the command prompt, it says host not found. Does any body else face this problem? Is there any other way to get the source for log4j v1.2?

    Read the article

  • In cakePHP, how to retrieve joined result from multiple tables

    - by Manish Sharma
    Hi, can anyone tell me, how to retrieve joined result from multiple tables in cakePHP ( using cakePHP mvc architecture). For example, I have three tables to join (tbl_topics, tbl_items, tbl_votes. Their relationship is defined as following: a topic can have many items and an item can have many votes. Now I want to retrieve a list of topics with the count of all votes on all items for each topic. The SQL query for this is written below: SELECT Topic.*, count(Vote.id) voteCount FROM tbl_topics AS Topic LEFT OUTER JOIN tbl_items AS Item ON (Topic.id = Item.topic_id) LEFT OUTER JOIN tbl_votes AS Vote ON (Item.id = Vote.item_id); My problem is I can do it easily using $this-><Model Name>->query function, but this requires sql code to be written in the controller which I don't want. I'm trying to find out any other way to do this (like find()).

    Read the article

  • Access is denied error with pregenerated .pyc or .pyo files

    - by mukul sharma
    Hi All, I am getting an Access is denied error while I am trying to run the .pyo file by double click or from the command prompt. Lets say I have abc.py (keeping main method entry point) which imports files xyz.py and imports wx etc. I generate the .pyo file. But once I try to run abc.pyo I get the access is denied error. I am not getting why this happening? Any help will really appreciated. Thanks

    Read the article

  • Themes wont work when using Server Side Tags on an ASP.NET Page

    - by Sumit Sharma
    The code for the asp.net page is: <div class="facebox_content"> <% if (CurrentUser.Role == "Free") { %> <table cellpadding="0" cellspacing="0" style="border-collapse:collapse;width:380px;"> <tr> <td> User Name : </td> <td> Membership Cost : </td> </tr> <tr> <td style="width:190px;"> <asp:TextBox ID="txtUserName" Enabled="false" runat="server" Text="<%= CurrentUser.Name %>"/> </td> <td style="width:190px;"> <asp:TextBox ID="txtCost" Enabled="false" runat="server" Text="2000"/> </td> </tr> <tr> <td> <br /> Cheque / Draft No.: </td> <td> <br /> Bank Drawn On : </td> </tr> <tr> <td style="width:190px;"> <asp:TextBox ID="txtChqNo" runat="server"></asp:TextBox> </td> <td style="width:190px;"> <asp:TextBox ID="txtBankName" runat="server"></asp:TextBox> </td> </tr> <tr> <td> <br /> Date : </td> <td> <br /> City : </td> </tr> <tr> <td style="width:190px;"> <asp:TextBox ID="txtDate" runat="server"></asp:TextBox> </td> <td style="width:190px;"> <asp:TextBox ID="txtCity" runat="server"></asp:TextBox> </td> </tr> </table> <% } else if(CurrentUser.Role == "Pending") { %> <p style="text-align:justify;"> Your Request is pending with our Administrators. Please be patient while your request is processed. Usually it takes 2-4 Days for your request to be processed after the payment has been received. </p> <% } else if(CurrentUser.Role == "Paid") { %> <p style="text-align:justify;"> You are already a Paid Member of Website </p> <% } %> The code for the C# file is: protected void Page_PreInit(object sender, EventArgs e) { this.Theme = CurrentUser.Theme; } protected void Page_Load(object sender, EventArgs e) { txtUserName.Text = CurrentUser.Name; ConfirmButton.Attributes.Add("onclick", "javascript:document.getElementById('" + lblMsg.ClientID + "').style.display='none';"); if (CurrentUser.Role != "Free") ConfirmButton.Visible = false; } The code is giving the following error: The Controls collection cannot be modified because the control contains code blocks (i.e. <% ... %>). Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Exception Details: System.Web.HttpException: The Controls collection cannot be modified because the control contains code blocks (i.e. <% ... %>). Source Error: An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below. Stack Trace: [HttpException (0x80004005): The Controls collection cannot be modified because the control contains code blocks (i.e. <% ... %>).] System.Web.UI.ControlCollection.Add(Control child) +8678903 System.Web.UI.PageTheme.SetStyleSheet() +478 System.Web.UI.Page.OnInit(EventArgs e) +8699660 System.Web.UI.Control.InitRecursive(Control namingContainer) +333 System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +378 Please some one help me out..!!

    Read the article

  • Getting error while transfering PGP file through FTP : The underlying connection was closed: An unex

    - by sumeet Sharma
    I am trying to upload a PGP encrypted file through FTP. But I am getting an error message as follows: The underlying connection was closed: An unexpected error occurred on a receive. I am using the following code and getting the error at line: Stream ftpStream = response.GetResponse(); Is there any one who can help me out ASAP. Following is the code sample: FtpWebRequest request = WebRequest.Create("ftp://ftp.website.com/sample.txt.pgp") as FtpWebRequest; request.UsePassive = true; FtpWebResponse response = request.GetResponse() as FtpWebResponse; Stream ftpStream = response.GetResponse(); int bufferSize = 8192; byte[] buffer = new byte[bufferSize]; using (FileStream fileStream = new FileStream("localfile.zip", FileMode.Create, FileAccess.Write)) { int nBytes; while((nBytes = ftpStream.Read(buffer, 0, bufferSize) > 0) { fileStream.Write(buffer, 0, nBytes); } } Regards, Sumeet

    Read the article

  • How do i start Game programming in windows phone xna?

    - by Ankit Rathod
    Hello, I am very much interested in Game programming in Xna. However during my college days i did not take Physics or Maths. Does that mean i can't create games in xna? I just know basics of trignometry. Can you all point me to few links where i can learn xna as well as the basic stuff of Maths that is bound to be required in most of the games? Are all game programmers excellent in Maths and Physics ? Thanks in advance :)

    Read the article

  • Where to find good 3d articles for wpf?

    - by Ankit Rathod
    Hello, I am beginner in WPF. I am basically a Silverlight guy and as i know it doesn't support the full real 3d model of WPF. I am getting interested in learning 3D in WPF. I googled up for WPF and i get very old links which are 3 years old back when WPF was known as Avalon. They may not be of any use in V4.0. Can anybody refer me some links where i can learn WPF 3D from basics? Thanks in advance :)

    Read the article

  • Why I am not able to update the column based on a condition which is not the primary key

    - by Gaurav Sharma
    Why I am not able to update the column based on a condition which is not the primary key. I am trying to update the constituencies table where name matches a specific criterial as shown below but the below queries shows an error Error code 1064, SQL state 42000: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'table constituencies set city_id = '1' where constituencies.name = "East Delhi"' at line 1 update table constituencies set city_id = '1' where constituencies.name = "East Delhi"; update table constituencies set city_id = '1' where constituencies.name = "South Delhi"; update table constituencies set city_id = '1' where constituencies.name = "Delhi Sadar"; update table constituencies set city_id = '1' where constituencies.name = "Karol Bagh"; update table constituencies set city_id = '1' where constituencies.name = "New Delhi"; update table constituencies set city_id = '1' where constituencies.name = "Outer Delhi"; update table constituencies set city_id = '1' where constituencies.name = "North East Delhi"; update table constituencies set city_id = '1' where constituencies.name = "North West Delhi"; update table constituencies set city_id = '1' where constituencies.name = "West Delhi"; Is it necessary that the condition should be checked with a primary key only ? Please throw some light on the above.

    Read the article

  • Software Evaluation license - How safe it is?

    - by Manav Sharma
    almost all the software companies across the globe offer an evaluation version for download. Often the terms and conditions are so many that it's not feasible to go through them. we usually skim through the pages to get to the download link. I was wondering how safe is that? I recently downloaded Rational PurifyPlus for evaluation and I expect that it would cease to function beyond the evaluation period. Are there any changes that the software would quietly move beyond the evaluation period without letting me know thus making me liable? Thanks

    Read the article

  • noscript tag appears even if javascript is turned on in IE8

    - by Gaurav Sharma
    ghost noscript tag more info here I am facing exactly this issue, how shall I handle this for Internet Explorer browsers :-( ? Explanation: I have included the following noscript tag in my application's layout <noscript style="background:#ffcc00;font-size:200%;font-family:verdana;text-align:center;text-transform:uppercase;font-weight:bold;padding:0.8em;">javascript is disabled, please enable it first.</noscript> Now when I view this layout in IE8 the noscript tag CSS is displaying at the top of the page without the content in it, making the layout look faulty. Please help...

    Read the article

  • router connect configuration in cakephp 1.3

    - by Gaurav Sharma
    Hello everyone, I have defined the following rule in the router.php file of my cakephp 1.3 based application Router::connect('/tags/*',array('plugin' => 'tags', 'controller' => 'Tags', 'action' => 'index', 'admin' => false)); I have used the tags plugin. When I display the tags related to a topic then the URL on the tags appears something like this http://localhost/testapp/tags/Tags/view/{tag_key_name} I want to make this url for any action to tags plugin like this http://localhost/testapp/Tags/{action}/{tag_key_name} for (view, admin_view and admin_edit) and http://localhost/testapp/Tags/{action} for (index, admin_index and any other action that does not require an id or keyname for execution)

    Read the article

  • How to handle HTTPStatus Response 201 with AS3 / Flash / SWFUpload

    - by Praveen Sharma
    Hey all. I'm using SWFUpload on a Rails site to allow for MP3 Uploads direct to Sound Cloud. To avoid having to first upload a large file to my server and push to Sound Cloud, I'm hitting their API directly via SWFUpload, passing necessary OAuth token data. Everything works - EXCEPT - Flash can't handle the HTTP response code that Sound Cloud's API returns (201). This ALWAYS triggers an unhandled IO Error with Flash. Even though SWFUpload allows me to override that in the JS, it breaks any response data (the URI to the uploaded file). Does anyone know how I could somehow intercept the 201 code so that I can make it a 200 code for flash? I'm at a loss at how I can avoid this IO Error. I've tried try/catch statements around everything and have even recompiled SWFUpload to try new things to no avail. Any help would be greatly appreciated.

    Read the article

  • using eval in server side code on asp.net page

    - by Sumit Sharma
    <asp:Repeater ID="rptrParent" runat="server"> <ItemTemplate> <li> <a href="<% =ResolveUrl("~/cPanel/UserView.aspx?User=")%><%# Eval("StudentUserName") %>"> <span> <% ProfileCommon pc = new ProfileCommon(); pc.GetProfile(Eval("StudentUserName").ToString()); Response.Write(pc.FirstName + "" + pc.LastName); %> <%# Eval("StudentUserName") %> </span> </a> </li> </ItemTemplate> The following error Databinding methods such as Eval(), XPath(), and Bind() can only be used in the context of a databound control. is coming in this part <% ProfileCommon pc = new ProfileCommon(); pc.GetProfile(Eval("StudentUserName").ToString()); Response.Write(pc.FirstName + "" + pc.LastName); %>

    Read the article

  • How do I show information to users belonging to different groups (web) in modx

    - by Gaurav Sharma
    Hello Everyone, I have created a website using modx evolution v1.0.2. The website that I have developed has 12 different types of users (categorized in groups). Each user will be shown a different price depending on the group to which he belongs. Till now I have been able to fetch the group name of current logged in user (created a snippet for that), but how can I achieve the above mentioned functionality so that each user should be able to see only the price that I have coded according to his group. For example: If a user is associated with the 'ocassional' group then he should be shown the price as , say, 50 bucks and if a user is associated with the 'regular' group then he should be shown the price as, say, 40 bucks I can easily do this by coding a single snippet for every product's variant, but there are a lot of variants (more than 100 and growing). I have created a resource(page) for every product and it's variant. Every variant has a price. It is this price that I want to be shown according to the logged in user group membership. I hope I am able to explain my query clearly. Please help me do this functionality. Thanks

    Read the article

  • How can I implement Unix grep in Perl?

    - by Ankit Rathod
    How can I implement grep of Unix in Perl? I tried to use Perl's built-in grep. Here is the code which is not working: $pattern = @ARGV[0]; $file= @ARGV[1]; open($fp,$file); @arr = <$fp>; @lines = grep $pattern, @arr; close($fp); print @lines; And by the way, i am trying only basic grep functionality not full featured and secondly i don't want to do string parsing myself. I want to use inbuilt grep or some function of Perl. Thanks in advance :)

    Read the article

< Previous Page | 3 4 5 6 7 8 9 10 11 12 13 14  | Next Page >