Search Results

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

Page 246/1260 | < Previous Page | 242 243 244 245 246 247 248 249 250 251 252 253  | Next Page >

  • Adding links to full change forms for inline items in django admin?

    - by David Eyk
    I have a standard admin change form for an object, with the usual StackedInline forms for a ForeignKey relationship. I would like to be able to link each inline item to its corresponding full-sized change form, as the inline item has inlined items of its own, and I can't nest them. I've tried everything from custom widgets to custom templates, and can't make anything work. So far, the "solutions" I've seen in the form of snippets just plain don't seem to work for inlines. I'm getting ready to try some DOM hacking with jQuery just to get it working and move on. I hope I must be missing something very simple, as this seems like such a simple task! Using Django 1.2.

    Read the article

  • Real average filesize in a set of files...

    - by JD
    Hi, I have an apparently "simple" problem but I can't find the solution for some reason... I have n millions files of different sizes and I want to find the average filesize. To simplify it, I grouped them in multiples of 16KB. < 16 KB = 18689546 files < 32 KB = 1365713 files < 48 KB = 1168186 files ... Of course, the simple (total_size / number of files) does not work. It gives an average of 291KB... What would be the algorithm to calculate the real average...? Thx, JD

    Read the article

  • Efficiently making web pages from multiple servers

    - by james.bcn
    I want to create a service that allows diverse web site owners to integrate material from my web servers into content served from their own servers. Ideally the resulting web page would only be delivered from the web site owners server, and the included content would be viewed as being part of the site by Google - which I think would rule out iframes or client-side Javascript to get the content from my server (although I may be wrong about that?). Also the data wouldn't actually be updated that often, say once a day, so it would be inefficient to get the data from my web servers with every request. Finally, the method needs to be as simple as possible so that it is easy for web site owners to integrate into their own sites. Are there any good methods for doing this sort of thing? If not then I guess the simple way is with iframes or Javascript.

    Read the article

  • Virtual machine on ubuntu

    - by MITHIYA MOIZ
    I have configured virtual machine on ubuntu with the help of below article, https://help.ubuntu.com/9.04/serverguide/C/libvirt.html I managed to finish all the part except the major portion getting virtual host to talk to real network, Which I guess should be done only via bridge interface. Via virtual machine manager I try to choose any interface it gives me interface not bridged When I try to bridge the interceface eth0 as below auto br0 iface br0 inet static address 192.168.0.223 network 192.168.0.0 netmask 255.255.255.0 broadcast 192.168.0.255 gateway 192.168.0.1 bridge_ports eth0 bridge_fd 9 bridge_hello 2 bridge_maxage 12 bridge_stp off I cannot communicate with this interface to network, host server looses all the communication to network. But when I remote bridge interface from /etc/network/interfaces And configure eth0 as below it works fine The primary network interface auto eth0 iface eth0 inet static address 192.168.0.223 netmask 255.255.255.0 network 192.168.0.0 broadcast 192.168.0.255 dns-nameservers 62.215.6.51 gateway 192.168.0.1 how can i setup bridge interface correctly and how would my /etc/netwrok/interfaces file would look a like.

    Read the article

  • Justified navigation buttons

    - by Kaivosukeltaja
    I'm trying to create the primary navigation menu for a website that will have a variable amount of primary menu items. The navigation bar is horizontal and has a width of 738px. I would like to have the leftmost item 18px from the left and the rightmost item 18px from the right edge of the element, with the other menu items spread evenly between them. I'm using a tableless layout. So far I haven't been able to make it work exactly like I want. Setting margin: auto doesn't seem to help, and I can't keep the 18px margin on both sides using a table. One idea was to use text-align: justify but it doesn't justify single lines. Is there a simple or less simple way of doing this, or am I going to have to ask the AD to relax his visual requirements?

    Read the article

  • Looking for the most painless non-RDBMS storage method in C#

    - by NateD
    I'm writing a simple program that will run entirely client-side. (Desktop programming? do people still do that?) and I need a simple way to store trivial amounts of data in a structured form, but really don't see any need to use a database system. What's more, some of the data needs to be serialized and passed around to different users, like some kind of "file" or perhaps a "document". (has anyone ever done that before?) So, I've looked at using .Net DataSets, LINQ, direct XML manipulation, and they all seem like they would get the job done, but I would like to know before I dive into any of them if there's one method that is generally regarded as easier to code than others. As I said, the amount of data to be stored is trivial, even if one hundred people all used the same machine we're not talking about more than 10 MB, so performance is not as large a concern as is codeability/maintainability. Thank you all in advance!

    Read the article

  • Rewriting Live TCP Streams

    - by user213060
    I want to rewrite TCP/IP streams. Ettercap's etterfilter command lets you perform simple live replacements of TCP/IP data based on fixed strings or regexes. Example: http://ettercap.sourceforge.net/forum/viewtopic.php?t=2833 I would like to rewrite streams based on my own filter program instead of just simple string replacements. Anyone have an idea of how to do this? Is there anything other than Ettercap that can do live replacement like this, maybe as a plugin to a VPN software or something? Thanks!

    Read the article

  • Can't access a partion that has a virus on it

    - by vaccano
    My wife's computer had a virus alarm go off, so I am looking into it. The virus is supposed to be on the D: drive. I wanted to talk a quick look at the file, but I cannot not. It has one file that I can get to. It is D:\Recovery. That shows a "Protected by PC Angel" graphic. How can I get past this? Should I do it? Is the virus scanner wrong? (I am using Avast).

    Read the article

  • What's the difference between "Flash Drive" and "Flash Memory"?

    - by Clive D
    I have a problem with a Blu ray disk I bought. I talked to a Sony technician who advised me to plug a "USB Flash Memory Stick" into the Blu-ray player. Is this something specific? Is there a difference between the following two? "USB Flash Drive" "USB Flash Memory" When I go to Curry's or other sites that sell USB Sticks, they only talk about "USB Flash Drives". I've been in computing for many years and know the basics, but "memory" and "drive" are different things to me.

    Read the article

  • When to use MVP in Windows Forms .net application?

    - by Janalopa
    I am familiar with MVC/MVP though my question is simple, I'm about to program a simple Instant Messaging software when the engine and communication part is an open API. so my software will have about 3 forms, a splash screen with login details, the options form and a main form with all the functionality like: Friends List, Send message, Received messages (tabbed), search user, etc. In UI perspective, its important for the GUI to be in 1 form in my application. So my question is, for the only complicated form that I'm going to have, is it necessary to implement an MVP design pattern or in this case its better to just go straight forward and put all the logic in 1 place? THANKS Janalopa!

    Read the article

  • Force an LXC container to use its own IP address

    - by emma sculateur
    Sorry if this question has already been asked. I could not find it, I have this setup : +---------------------------------------------------------------------------------------------+ |HOST | | | | +-------------------------------------------------+ | | | UBUNTU-VM | | | | | | | | +-------------------+ | | | | |UBUNTU-LXC | | +------------------+ | | | | 10.0.0.3/24 | 10.0.0.1/24 | |OTHER VM | | | | | eth0-----lxcbr0----------eth0-----------br0----------eth0 | | | | | | 192.168.100.2/24| 192.168.100.1/24 |192.168.100.3/24 | | | | +-------------------+ | +------------------+ | | +-------------------------------------------------+ | +---------------------------------------------------------------------------------------------+ When I ping 192.168.100.3 from my UBUNTU-LXC, the source IP address is automatically changed to 192.168.100.2 by UBUNTU-VM. It's like having a NAT, whereas I really want my UBUNTU-LXC to talk with it own IP address. Is there any way to do this ? Edit : these info may be relevant : I am using KVM +libvirt to set up my VMs Here is how I create my interface in UBUNTU-VM : <interface type='bridge'> <mac address='52:54:00:cb:aa:74'/> <source bridge='br0'/> <model type='e1000'/> <address type='pci' domain='0x0000' bus='0x00' slot='0x09' function='0x0'/> </interface>

    Read the article

  • Windows HTTP proxy client to pass service requests to VPN

    - by Chris
    I've got access to a network via CheckPoint VPN (Windows client). Problem is, I have a linux box that needs to talk to its web services and the target web servers are inside the VPN. So far, we have been unable to connect linux to the VPN (and I'm not trying to solve that problem at the moment). I'm wondering if (temporarily) I can setup a proxy server on a Windows (XP) box to shuttle HTTP requests back and forth? If so, what'd be a good application to do this? (hopefully free/open-source) TIA

    Read the article

  • Simplest Way to Process Basic HTTPS GET File Requests?

    - by stormin986
    All I need to do is download some basic text-based and image files from a web server that has a self-signed SSL certificate. I have been trying to figure out how to use HttpClient to do this, but getting the SSL to work is a nightmare that seems to be way too much trouble for such a simple task. Is there a better way to perform these file downloads? Perhaps through a WebView or Browser feature? Reinventing the wheel of making a simple HTTPS GET request is a major pain, and is significantly holding up my development schedule.

    Read the article

  • SQL Having Clause

    - by Wally
    I'm trying to get a stored procedure to work using the following syntax: select count(sl.Item_Number) as NumOccurrences from spv3SalesDocument as sd left outer join spv3saleslineitem as sl on sd.Sales_Doc_Type = sl.Sales_Doc_Type and sd.Sales_Doc_Num = sl.Sales_Doc_Num where sd.Sales_Doc_Type='ORDER' and sd.Sales_Doc_Num='OREQP0000170' and sl.Item_Number = 'MCN-USF' group by sl.Item_Number having count (distinct sl.Item_Number) = 0 In this particular case when the criteria is not met the query returns no records and the 'count' is just blank. I need a 0 returned so that I can apply a condition instead of just nothing. I'm guessing it is a fairly simple fix but beyond my simple brain capacity. Any help is greatly appreciated. Wally

    Read the article

  • How to use Netbeans platform syntax highlight with JEditorPane?

    - by Volta
    There are many tutorials online giving very complex or non-working examples on this. It seems that people recommend others to use the syntax highlighters offered by netbeans but I am totally puzzled on how to do so! I have checked many many sites on this and the best I can find is : http://www.antonioshome.net/kitchen/netbeans/nbms-standalone.php However I am still not able to use this example (as it is aimed to people who don't want to use the Netbeans platform but just a portion of it) and I am still not sure if I can just use syntax highlighting in a simple plug 'n play way. For example netbeans supports several language highlights by default, can I just use the highlighters in a JEditorPane to parse Ruby/Python/Java for example ? or do I need to write my own parser :-| ? I will really appreciate a small simple example on how to plug syntax highlight in a standalone application using the netbeans platform.

    Read the article

  • translate by replacing words inside existing text

    - by Berry Tsakala
    What are common approaches for translating certain words (or expressions) inside a given text, when the text must be reconstructed (with punctuations and everythin.) ? The translation comes from a lookup table, and covers words, collocations, and emoticons like L33t, CUL8R, :-), etc. Simple string search-and-replace is not enough since it can replace part of longer words (cat dog ? caterpillar dogerpillar). Assume the following input: s = "dogbert, started a dilbert dilbertion proces cat-bert :-)" after translation, i should receive something like: result = "anna, started a george dilbertion process cat-bert smiley" I can't simply tokenize, since i loose punctuations and word positions. Regular expressions, works for normal words, but don't catch special expressions like the smiley :-) but it does . re.sub(r'\bword\b','translation',s) ==> translation re.sub(r'\b:-\)\b','smiley',s) ==> :-) for now i'm using the above mentioned regex, and simple replace for the non-alphanumeric words, but it's far from being bulletproof. (p.s. i'm using python)

    Read the article

  • Spring 3 Annotations

    - by jboyd
    I can't get spring annotations to work at all, I'm just trying to get the simplest thing to work... .../mycontext/something - invokes method: @RequestMapping(value = "/something") @ResponseBody public String helloWorld() { System.out.println("hello world"); return "Hello World"; } My main problem is no matter how hard I try, I can't find a complete SIMPLE example of the configuration files needed, every spring tutorial is filled with junk, I just one one controller to handle a request with a mapping and can't get it to work does anyone know of a simple and complete spring example. pet-clinic is no good, it's way too complicated, I have a tiny basic use case and it's proving to be a real pain to get working (this always happens with Spring)

    Read the article

  • How to build an interactive search engine web interface using python

    - by asmaier
    I have build a static web interface for searching data from some tables in my PostgreSQL database. The query website consists of a simple textfield for entering the search term, the result website presents the results as a simple html table. The server side code for searching the PostgreSQL database and returning the results is written in python using psycopg2. Now I would like to add some interactive "Ajax features" to my search engine. When entering the search term I would like to be able to see a list of possible search terms like Google does it. On the results page, I would like to be able to sort the table showing the results. What would be the easiest/recommended way to implement these features for my search engine web site? Do I need a full-fledged web framework like Django for that?

    Read the article

  • Tool for parsing smtp logs that finds bounces

    - by Željko Filipin
    Our web application sends e-mails. We have lots of users, and we get lots of bounces. For example, user changes company and his company e-mail is no longer valid. To find bounces, I parse smtp log file with log parser. Some bounces are great, like 550+#[email protected]. There is [email protected] in bounce. But some do not have e-mail in error message, like 550+No+such+recipient. I have created simple ruby script that parses logs (uses log parser) to find which mail caused something like 550+No+such+recipient. I am just surprised that I could not find a tool that does it. I have found tools like zabbix and splunk for log analysis, but they look like overkill for such simple task. Anybody knows a tool that would parse smtp logs, find bounces and e-mails that cause them? Edit: smtp server is microsoft smtp server.

    Read the article

  • JTable.setRowHeight prevents me from adding more rows

    - by Brent Parker
    I'm working on a pretty simple Java app in order to learn more about JTables, TableModels, and custom cell renderers. The table is a simple table with 8 columns only with text in them. When you click on an "add" button, a dialog pops up and lets you enter the data for the columns. Now to my problem. One of the columns (the last one) should allow for multiple lines of text. I'm already putting HTML into the field, but it is not wrapping. I did some research and looked into JTable#setRowHeight(). However, once I use setRowHeight, I can no longer add rows to the table. The data is put into the table model, but it does not show in the table. If I remove the setRowHeight line, then it adds data just fine. Is there another step to adding data to my data model that I'm missing? Thanks a lot!

    Read the article

  • SQL Server view: how to add missing rows using interpolation

    - by Christopher Klein
    Running into a problem. I have a table defined to hold the values of the daily treasury yield curve. It's a pretty simple table used for historical lookup of values. There are notibly some gaps in the table on year 4, 6, 8, 9, 11-19 and 21-29. The formula is pretty simple in that to calculate year 4 it's 0.5*Year3Value + 0.5*Year5Value. The problem is how can I write a VIEW that can return the missing years? I could probably do it in a stored procedure but the end result needs to be a view.

    Read the article

  • Best way to implement a Rest API with PHP on Wamp web server

    - by DomingoSL
    Hello, i own a web server running windows (WAMP). I want to know the best way to implement a Rest API (a very simple one) in order to let a user do something. Diagram flow: I have programming skills, in fact, i developed some time ago a web server in VB6 who process the querys and when it find the command (http:/serverIP/webform.php?cmd=run&item=any) it do something, but know i really want to develop a solution using the WAMP server. Some people consider the solution of executing a exe when a command is detected a bad solution for security issues, but this specific proyect i have is for the use of only some people (trusted people) who dont have intentions of hacking the server. So, what do you think? Remember: Its not a public API, its for some people and some programs who will use the API Its a very simple one, only one command using POST or GET. Thanks

    Read the article

  • Is there a lightweight MTA for Ubuntu 9.10 Desktop?

    - by Joe Casadonte
    I'm writing a Perl script to run as a cron job, and I want to email results & errors to a local account on the laptop. I'd like something that can talk SMTP (do any MTAs not adhere to SMTP?). I use Thunderbird 3, so I'll also need a POP/IMAP server (unless T-Bird can read straight from an mbox file; I'll have to check into that). No need for spam controls as I'll lock it down real tight, only accepting mail originating from the laptop itself. Thanks!

    Read the article

  • Hash 32bit int to 16bit int?

    - by dkamins
    What are some simple ways to hash a 32-bit integer (e.g. IP address, e.g. Unix time_t, etc.) down to a 16-bit integer? E.g. hash_32b_to_16b(0x12345678) might return 0xABCD. Let's start with this as a horrible but functional example solution: function hash_32b_to_16b(val32b) { return val32b % 0xffff; } Question is specifically about JavaScript, but feel free to add any language-neutral solutions, preferably without using library functions. Simple = good. Wacky+obfuscated = amusing.

    Read the article

< Previous Page | 242 243 244 245 246 247 248 249 250 251 252 253  | Next Page >