Search Results

Search found 31491 results on 1260 pages for 'simple talk'.

Page 86/1260 | < Previous Page | 82 83 84 85 86 87 88 89 90 91 92 93  | Next Page >

  • How do I handle the messages for a simple web-based live chat, on the server side?

    - by Carson Myers
    I'm building a simple live chat into a web application running on Django, but one thing I'm confused about is how I should store the messages between users. The chat will support multiple users, and a chat "session" is composed of users connected to one user that is the "host." The application is a sort of online document collaboration thing, so user X has a document, and users Y and Z would connect to user X to talk about the document, and that would be one chat session. If user Y disconnected for five minutes, and then signed back in and reconnected to user X, he should not get any of the messages shared between users X and Z while he was away. if users X, Y, and Z can have a chat session about user X's document, then users X and Y can connect to a simultaneous, but separate discussion about user Z's document. How should I handle this? Should I keep each message in the database? Each message would have an owner user and a target user (the host), and a separate table would be used to connect users with messages (which messages are visible to what users). Or should I store each session as an HTML file on the server, which messages get appended to? The problem is, I can't just send messages directly between clients. They have to be sent to the server in a POST request, and then each client has to periodically check for the messages in a GET request. Except I can't just have each message cleared after a client fetches it, because there could be multiple clients. How should I set this up? Any suggestions?

    Read the article

  • SNIReadSync executing between 120-500 ms for a simple query. What do I look for?

    - by Mike
    Hi Stackoverflow, I am executing a simple query against SQL Server 2005: protected static void InitConnection(IDbCommand cmd) { cmd.CommandText = "set transaction isolation level read uncommitted "; cmd.ExecuteNonQuery(); } Whenever I profile with dotTrace 3.1, it claims that SNIReadSync method is taking between 100 - 500 ms. What sort of things do I need to be looking for in order to get this time down? Thanks!

    Read the article

  • Is reading xml simple in rails or converting it to hash will be simpler?

    - by Salil
    Hi All, Sorry for this question but after spending 1-2 hours on how to read xml, i thought posting it on forum will be better. So i get a complex (very large)xml response from the plugin trackify. i want to read some values form it so i covert it into hash and then read it as follows For ex:- to read city @tracking_info['TrackResponse']['Shipment']['ShipTo']['Address']['City'] #>> "SEATTLE" my question is it proper way to getting xml response or there are some xml methods which is simple to use?

    Read the article

  • KISS: Simple C# application which communicates with a RESTful web service.

    - by Workshop Alex
    Following the KISS principle, I suddenly realised the following: In .NET, you can use the Entity Model Framework to wrap around a database. This model can be exposed as a web service through WCF. This web service would have a very standardized definition. A client application could be created which could consume any such RESTful web service. I don't want to re-invent the wheel and it wouldn't surprise me if someone has already done this, so my question is simple: Has anyone already created a simple (desktop, not web) client application that can consume a RESTful service that's based on the Entity Framework and which will allow the user to read and write data directly to this service? Otherwise, I'll just have to "invent" this myself. :-)Problem is, the database layer and RESTful service is already finished. The RESTful service will only stay in the project during it's development phase, since we can use the database-layer assembly directly from the web applications that are build around it. When the web application is deployed, the RESTful services are just kept out of the deployment. But the database has a lot of data to manage over nearly 50 tables. When developing against a local database, we can have straight access to the database so I wouldn't need this tool for this. When it's deployed, the web application would be the only way to access the data so I could not use this tool. But we're also having a test phase where the database is stored on another system outside the local domain and this database is not available for developers. Only administrators have direct access to this database, making tests a bit more complex. However, through the RESTful service, I can still access the data directly. Thus, when some test goes wrong, I can repair the data through this connection or just create a copy of the data for tests on my local system. There's plenty of other functionality and it's even possible to just open the URL to a table service straight in Excel or XMLSpy to see the contents. But when I want to write something back, I have to write special code to do just that. A generic tool that would allow me to access the data and modify it would be easier. Since it's a generic setup around the ADO.NET Data services, this should be reasonable easy too. Thus, I can do it but hoped someone else has already done something similar. But it appears that there's no such tool made yet...

    Read the article

  • Creating a simple templated control. Having issues...

    - by Jimock
    Hi, I'm trying to create a really simple templated control. I've never done it before, but I know a lot of my controls I have created in the past would have greatly benefited if I included templating ability - so I'm learning now. The problem I have is that my template is outputted on the page but my property value is not. So all I get is the static text which I include in my template. I must be doing something correctly because the control doesn't cause any errors, so it knows my public property exists. (e.g. if I try to use Container.ThisDoesntExist it throws an exception). I'd appreciate some help on this. I may be just being a complete muppet and missing something. Online tutorials on simple templated server controls seem few and far between, so if you know of one I'd like to know about it. A cut down version of my code is below. Many Thanks, James Here is my code for the control: [ParseChildren(true)] public class TemplatedControl : Control, INamingContainer { private TemplatedControlContainer theContainer; [TemplateContainer(typeof(TemplatedControlContainer)), PersistenceMode(PersistenceMode.InnerProperty)] public ITemplate ItemTemplate { get; set; } protected override void CreateChildControls() { Controls.Clear(); theContainer = new TemplatedControlContainer("Hello World"); this.ItemTemplate.InstantiateIn(theContainer); Controls.Add(theContainer); } } Here is my code for the container: [ToolboxItem(false)] public class TemplatedControlContainer : Control, INamingContainer { private string myString; public string MyString { get { return myString; } } internal TemplatedControlContainer(string mystr) { this.myString = mystr; } } Here is my mark up: <my:TemplatedControl runat="server"> <ItemTemplate> <div style="background-color: Black; color: White;"> Text Here: <%# Container.MyString %> </div> </ItemTemplate> </my:TemplatedControl>

    Read the article

  • Simple way to encode a string according to a password?

    - by RexE
    Does Python have a built-in, simple way of encoding/decoding strings using a password? Something like this: >>> encode('John Doe', password = 'mypass') 'sjkl28cn2sx0' >>> decode('sjkl28cn2sx0', password = 'mypass') 'John Doe' I would like to use these encrypted strings as URL parameters. My goal is obfuscation, not strong security. I realize I could use a database table to store keys and values, but am trying to be minimalist.

    Read the article

  • Nice, clean, simple way of getting a dataset from ASP.NET to plain HTML jQuery or JavaScript library

    - by David S
    I know this is a probable open ended question, and I have tried looking around so much over the last year or two... maybe I am looking for a perfect place that doesn't exist! of course it's all about perception no less.. Anyway, just to clarify what I am trying to do and why: I want to be able to use (primarily for the moment) ASP.NET or services thereof to get a dataset - whatever the source data, I can obviously get a dataset of rows/Columns. I want to be able to, as simply as possible, get that data over to the client via xml/json/whatever, to then use in a "variety" of ways. "Variety" of ways meaning I would like to "easily" bind that data to say a grid, or a combo dropdown or just simply render to a textbox - BUT by referencing the dataset as I would say on the serverside. Now I know this all sounds simplistic, and I know there are lots of complications.. so I have tried the following so far over the last year or so: ExtJS - very good, nice solid framework, but just found it a bit too much to use in everyday basic apps - great if I was building a whole application with it Yahoo YUI - not looked recently, but I guess some of the concepts with ExtJS were similar? JQuery - of course to get data etc, it was ok, and I guess there are so many 3rd party plugins, that a mix and match might work? Adobe SPRY - ironically this was as close to getting a dataset style structure to Javascript/client, although it seemed to drop off/go quiet..? I maybe wrong.. I did have a very cursory play with Tibco GI and another one I cannot remember the name of! but again, it felt like it was great to build a whole app perhaps? Anyway, I am very amazed by all of the technologies coming out, and really not biased one way or the other, I really just want a very simple way of getting data from the server, and having a basic/very flexible way of working with that data in the client without using server technologies.. I need to keep the server flexible as I may need to use PHP, or java technologies not just .NET So again, sorry for the rambles, but if anyone out there has had a simple experience, or would like to share some ideas, it would be very welcomed!! David.

    Read the article

  • can anyone please suggest some simple and short js for vertical multiple text scroll???

    - by developer
    I have a js running in my site that is for text scrolling.What is does is that it scrolls a text vertically upwards then holds for a second or two and then shows next text.Here you can have an idea of what i need and im using http://www.dynamicdrive.com/dynamicindex2/crosstick.htm What i need now is a simple and shorter dynamic js for this scrolling,somewhat around 2 kb or so......i have looked around internet but couldnt find one........please suggest some!!!

    Read the article

  • How could I apply a genetic algorithm to a simple game that follows rollercoaster tracks?

    - by Chris
    I have free-rein over what I do on a final assignment for school, with respect to modifying a simple direct-x game that currently just has the camera follow some rollercoaster rails. I've developed an interest in genetic algorithms and would like to take this opportunity to apply one and learn something about them. However, I can't think of any way I could possibly apply one in this case. What are some options available to me?

    Read the article

  • Simple CSS dropdown menu does not work in IE6 or 7 - please help.

    - by Jeff Jones
    Hi there. I'm using a very simple CSS dropdown menu which works well in most modern browsers. Unfortunately it must also work in IE6 and 7, which it currently does not. Can anyone please check it out very quickly and tell me if it can be easily fixed? I'm not adverse to using JavaScript if required. The markup and CSS: http://paste2.org/p/826583 Many thanks!

    Read the article

< Previous Page | 82 83 84 85 86 87 88 89 90 91 92 93  | Next Page >