Search Results

Search found 2068 results on 83 pages for 'thomas stock'.

Page 35/83 | < Previous Page | 31 32 33 34 35 36 37 38 39 40 41 42  | Next Page >

  • Symfony and uploadify

    - by Thomas
    Hi! I want to use uploadify with Symfony 1.4, but so far I couldn't. Uploadify loads correctly, I choose my files, it says that the files were successfully uploaded, but the are nowhere. (I'm doing this on localhost) Is there anybody who met this problem before? Thanks, Tom $file = $request->getParameter('file'); $filename = sha1($file->getOriginalName()).$file->getExtension($file->getOriginalExtension()); $file->save(sfConfig::get('sf_upload_dir').'/'.$filename);

    Read the article

  • Using Maven for project distribution

    - by Thomas
    I have an Project that I distribute by sending out large packages. I'd like to know if there is a user friendly way of using Maven to distribute updates of the project? I'd need something like what is done for updating softwares like Firefox or Acrobat Reader. Check a respository, warn user of an update, download and reconfigure. All within a simple and friendly interface. Alternative open source java projects are welcome.

    Read the article

  • How to access project files from NUnit tests

    - by Daren Thomas
    I have some Tests that I run with ReSharpers "Run All Tests from Solution" feature. One of the classes being tested has a dependency on a file in the same folder as the assembly containing it. This file is copied to the output directory via MSBuild (set "Copy To Output Directory" to "Copy always"). Problem: The tests are not being run from the normal assembly output directory, but instead some temporary location in my user profile. Therefore, I don't really know where to look for the file - the test runner does not copy it there. Can I force it to?

    Read the article

  • DDD and Entity Base, Model using multiple identity types

    - by Thomas
    I have a model that looks like this: public interface IEntity { int Id { get; set; } } Then the idea is to have my entities inherit from this interface: public class User : IEntity { public int Id { get; set; } } However, one of my entities actually has a Guid as an identifier. public class UserSession { public Guid Id { get; set; } } I really would like all my entities inheriting from the same interface but that would force me to add an integer based identity column to the UserSession which is unnecessary since Guid is the identity, but it would keep the domain model nice since all entities would inherit from the same base. What options do I have in this scenario? Can I have two base interfaces, one for int and one for Guid? Should I add an identity column into the UserSession entity although it is unnecessary? I need the Guid so I can't just get rid of it and replace it with and integer. Any thoughts on best practices?

    Read the article

  • How to stream semi-live audio over internet

    - by Thomas Tempelmann
    I want to write something like Skype, i.e. I have a constant audio stream on one computer and then recompress it in a format that's suitable for a latent internet connection, receive it on the other end and play it. Let's also assume that the internet connection is fairly modern and fast, i.e. DSL or alike, no slow connections over phone and such. The involved computers will also be rather modern (Dual Core Intel CPUs at 2GHz or more). I know how to handle the audio on the machines. What I don't know is how to transmit the audio in an efficient way. The challenges are: I'd like get good audio quality across the line. The stream should be received without drops. The stream may, however, be received with a little delay (a second delay is acceptable). I imagine that the transport software could first determine the average (and max) latency, then start the stream and tell the receiver to wait for that max latency before starting to play the audio. With that, if the latency doesn't get any higher, the entire stream will be playable on the other side without stutter or drops. If, due to unexpected IP latencies or blockages, the stream does get cut off, I want to be able to notice this so that I can take actions (e.g. abort the stream) and eventually start a new transmission. What are my options if I want do use ready-made software for the compression and tranmission? I have no intention to write my own audio compression engine, really. OTOH, I plan to sell the solution in a vertical market, meaning I can afford a few dollars of license fees per copy, but not $100s. I guess the simplest solution would be to just open a TCP stream, send a few packets back and forth to determine their running time (or even use UDP for that), then use the results as the guide for my max latency value, then simply fire the audio data in its raw form (uncompressed 16 bit stereo), along with a timing code over the TCP connection. The receiver reads the data and plays it with the pre-determined delay. That might just work with the type of fast connection I expect. I just wonder if there are better solutions to reach this goal, with better performance (lower latency) and less data (compressed). BTW, I first try to implement this on OS X, but might want to do it on Windows, too, if it proves successful.

    Read the article

  • Set two classes from array

    - by Thomas
    I want to change the classes on every third output from a query: <?php $style_classes = array('box','box','box no_right_margin'); $style_index = 0; ?> I set this on the div: <div <?php $k = $style_index%4; echo "class=$style_classes[$k]"; $style_index++; ?>> On the third div I want the class to look like this: <div class="box no_right_margin"> Right now it looks like: <div class="box" no_right_margin>

    Read the article

  • MySQL Trigger with dynamic table name

    - by Thomas
    I've look around a bit and can't quite find an answer to my problem: I want a trigger to execute after an insert on a table and to take that data that is being inserted and do two things Create a new table from the client id and partner id Insert the 'data' that just was inserted into the new table I am fairly new to the Stored procedures and triggers so I came up with this but am having difficulty debugging it: delimiter $$ CREATE TRIGGER trg_creas_insert BEFORE INSERT ON tracking.creas for each row BEGIN DECLARE @tableName varchar(40); DECLARE @createStmnt mediumtext; SET @tableName = concat('crea_','_', NEW.idClient_crea,'_',NEW.idPartenaire_crea); SET @createStmnt = concat('CREATE TABLE IF NOT EXISTS', @tableName, '( `data_crea` mediumtext NOT NULL ) ENGINE=MyISAM AUTO_INCREMENT=29483330 DEFAULT CHARSET=utf8 PACK_KEYS=0'); PREPARE stmt FROM @createStmnt; EXECUTE stmt; INSERT INTO @tableName (data_crea) values (NEW.data_crea); END$$ delimiter ; Thoughts?

    Read the article

  • Extracting an interface from .NEt System classes

    - by Thomas
    When using Visual Studio it is easy to extract an interface from a class that I have written myself. I right click on the class and select 'Refactor' then select 'Extract Interface'. Let's assume for a second that I wanted to create a ConfigurationManager wrapper and write some tests around it. A quick way to do that would be to extract an interface from ConfigurationManager by right clicking it, then 'Go To Definition' and then from inside the class select 'Refactor' then select 'Extract Interface'. Then I would simply create my wrapper class, inherit from my newly created interface, and then implement it and I have a great starting point for my wrapper class. However, extracting an interface from any .NET system classes is not possible, probably because it's just meta data about the classes and not the classes themselves (or I am doing it wrong). Is there an easy way to do what I am trying to accomplish? I want to ensure I am not wasting time typing what I don't need to be typing. Thanks

    Read the article

  • How to block non-browser clients from submitting a request?

    - by Thomas Kohl
    I want to block non-browser clients from accessing certain pages / successfully making a request. The website content is served to authenticated users. What happens is that our user gives his credentials to our website to 3rd party - it can be another website or a mobile application - that performs requests on his behalf. Say there is a form that the user fills out and sends a message. Can I protect this form so that the server processing the submission can tell whether the user has submitted it directly from the browser or not? I don't want to use CAPTCHA for usability reasons. Can I do it with some javascript?

    Read the article

  • How do you hook a C++ compiled dll function to a sql database?

    - by Thomas
    I want to do something like: lastName SIMILARTO(lastName, 'Schwarseneger', 2) where lastName is the field in the database, 'Schwarseneger' is the value that lastName field is being compared to and 2 is the maximum number of characters (edit distance) that can differ between the lastName field, and the entered value. I can implement the SIMILARTO function in C++ using the Levenshtein distance (http://en.wikipedia.org/wiki/Levenshtein_distance), but how do hook the function in a dll to a mySQL implementation?

    Read the article

  • Silverlight Isolated Storage and loading big files

    - by Thomas Joulin
    In a Windows Phone 7 application, I would like to query a big XML file (list of cities) stored using Isolated Storage. If I do that this way, will the file be loaded to memory ( 5 mo) ? If so, what other solution do I have? Edit: More details. I want to use AutoCompleteBox (http://www.jeff.wilcox.name/2008/10/introducing-autocompletebox/), but instead of using a web service (this is fixed data, no need to be online), I want to query a file/database/isolated storage... I have a fixed list of cities. I said in the comments it's 40k, but it finally seems closer to 1k rows.

    Read the article

  • Can Adobe AIR display SVG?

    - by Ed Thomas
    I see that Adobe AIR uses WebKit as its render and I see that WebKit (at least the most current build) has some SVG support. Does this mean (and has anyone specifically tried) that an Adobe AIR application could render SVG on an HTML page?

    Read the article

  • How can I display image and text within one AS3 datagrid?

    - by Thomas
    The following page shows how to load external images in AS3 DataGrid: http://www.adobe.com/devnet/flash/quickstart/datagrid_pt3/ (image and text are displayed in two columns) But I wonder how the image and text can be loaded together within the same DataGrid. Within one column: Image followed by the text. I cannot get it work so I'd be grateful for any help with examples. Thanks

    Read the article

  • How to prevent autoplay and run my own app when inserting an USB-Flash drive

    - by Thomas
    when inserting an USB-Flash drive, Windows normally opens the Autoplay dialog that offers to browse the drive or if there are multimedia files it offers to choose an app to open them. We developed a media player that is connected to the USB-Drive and registers itself as Mass Storage Device. What I need is, that when inserting the Player that this Dialog is not shown, but instead my own application is launched. Ideally the application would be on the Flash Drive itself, but as I understood is that Autorun is disabled for USB-Drives. It would be enough if a preinstalled application is launched. I already tried to catch the WM_DRIVE_CHANGE message, but this only works if my application is the top most window, otherwise the Autoplay Dialog is displayed. Best Tom

    Read the article

  • How can my facebook application post message to a wall?

    - by Thomas Dekiere
    i already found out how to post something to a wall with the graph api on behalf of the facebook user. But now i want to post something in the name of my application. Here is how i'm trying to do this: protected void btn_submit_Click(object sender, EventArgs e) { Dictionary<string, string> data = new Dictionary<string, string>(); data.Add("message", "Testing"); // i'll add more data later here (picture, link, ...) data.Add("access_token", FbGraphApi.getAppToken()); FbGraphApi.postOnWall(ConfigSettings.getFbPageId(), data); } FbGraphApi.getAppToken() // ... private static string graphUrl = "https://graph.facebook.com"; //... public static string getAppToken() { MyWebRequest req = new MyWebRequest(graphUrl + "/" + "oauth/access_token?type=client_cred&client_id=" + ConfigSettings.getAppID() + "&client_secret=" + ConfigSettings.getAppSecret(), "GET"); return req.GetResponse().Split('=')[1]; } FbGraphApi.postOnWall() public static void postOnWall(string id, Dictionary<string,string> args) { call(id, "feed", args); } FbGraphApi.call() private static void call(string id, string method, Dictionary<string,string> args ) { string data = ""; foreach (KeyValuePair<string, string> arg in args) { data += arg.Key + "=" + arg.Value + "&"; } MyWebRequest req = new MyWebRequest(graphUrl +"/" + id + "/" + method, "POST", data.Substring(0, data.Length - 1)); req.GetResponse(); // here i get: "The remote server returned an error: (403) Forbidden." } Does anyone see where this i going wrong? I'm really stuck on this. Thanks!

    Read the article

  • How can I preview the contents of books sold on Amazon in Internet Explorer 10?

    - by Aceman
    I run 64-bit Windows 7 and have both Internet Explorer 10 and a newly-downloaded copy of Google Chrome. I downloaded the latter when I found that I could not look (preview) the contents of books sold on Amazon (using it "Look Inside" feature) and wanted to try to get a handle on how extensive the problem was (i.e., whether it occurred on other browsers, too). It turns out that this isn't a problem with Chrome. However, I have grown accustomed over the years to IE and would prefer to resolve this problem instead. Here's an example of my attempt to 'Search Inside' a book on sale at Amazon: http://www.amazon.com/Intellectuals-Race-Thomas-Sowell/dp/0465058728/ref=sr_1_1?s=books&ie=UTF8&qid=1382301764&sr=1-1&keywords=thomas+sowell#reader_0465058728 I understand that I can't (as is the case in some technical support websites) add a screen shot (ie. JPG to this), but if I were to describe what this looks like in IE, the area where the text would appear appears as a blank white page with horizontal lines where the text would ordinarily be. I have just examined this posting of mine via Chrome and the contents of the selected page are clearly visible.

    Read the article

  • How to diff two regions of the same file in Eclipse

    - by Thomas Nilsson
    I'm a TDDer and often have a need to refactor out common or similar code. If it is exactly the same there is no big problem, Eclipse can almost always do that by itself. But to get there I'm finding myself often looking at similar, but not identical, code fragments in the same, or even different, files. It would be very handy if there was a possibility to mark two regions and get Eclipse (or some other tool) to mark the differences. With this information it would be much simpler to iteratively move the regions closer until they are the same and then activate the Extract Method refactoring. It can be done in Emacs of course, but I'd like to have this readily available from Eclipse. Any pointers?

    Read the article

  • Get ViewData IList back on postback in ASP.NET MVC

    - by Thomas
    I have the following in my view: <%using (Html.BeginForm()) {%> <% foreach (var item in Model.Cart) { %> <div> <%= Html.TextBox("Cart.Quantity", item.Quantity, new { maxlength = "2" })%> <%= Html.Hidden("Cart.ItemID", item.ItemID)%> </div> <% } %> <input name="update" type="image" src="image.gif" /> <% } % I then have this code in my controller: public ActionResult Index() { CartViewData cartViewData = new CartViewData(); IList<Item> items = ItemManager.GetItems(); cartViewData.Cart = items; return View("Index", cartViewData); } [AcceptVerbs(HttpVerbs.Post)] public ActionResult Index(CartViewData cartViewData) { // cartviewData is null } Is there a way to grab the List on the postback to see if the values in the textboxes have changed? Thanks Below is a simplified example since it was requested: <% for (int i = 0; i < Model.Cart.Count; i++ ) { %> <a href="javascript:void(0);" onclick="removeItem(<%= Model.Cart[i].ShoppingCartItemID %>);">Remove</a> <% } %> Hope this helps.

    Read the article

  • Apply a specific class to the first item in a series with PHP

    - by Thomas
    I have a php script that echoes a series of uploaded images and I need to apply a class to the first image echoed in the series. Is this possible? For example, if I want to display 10 images and apply a class to only the first image, how would I go about it? Here is the code, I am working with: <div id="gallery"> <?php query_posts('cat=7'); while(have_posts()) { the_post(); $image_tag = wp_get_post_image('return_html=true'); $resized_img = getphpthumburl($image_tag,'h=387&w=587&zc=1'); $url = get_permalink(); $Price ='Price'; $Location = 'Location'; $title = $post->post_title; echo "<a href='$url'><img src='$resized_img' width='587' height='387' "; echo "rel=\"<div class='gallery_title'><h2>"; echo $title; echo "</h2></div>"; echo "<div class='pre_box'>Rate:</div><div class='entry'>\$"; echo get_post_meta($post->ID, $Price, true); echo "</div><div class='pre_box'>Location:</div><div class='entry'>"; echo get_post_meta($post->ID, $Location, true); echo "</div>\""; echo "'/></a>"; echo ""; } ?> On line 13, the code looks like this: echo "<a href='$url'><img src='$resized_img' width='587' height='387' "; For the first item only, I need it to look like this: echo "<a href='$url' class='show'><img src='$resized_img' width='587' height='387' ";

    Read the article

  • Weird Behavior with Jquery image slideshow... Help!

    - by Thomas
    I built a jquery slideshow based on the tutorial found here: http://www.queness.com/post/152/simple-jquery-image-slide-show-with-semi-transparent-caption It seems to be working perfectly fine, except that it behaves strangley right at the beginning when it displays the first image. The first image appears like normal and then flashes, fades to white and disappears completely. After that, the first slide reappears and behaves normally, transitioning to the next image. The slideshow in question is center page on the right: http://www.loftist.com/ I am not a JS developer, so I am not sure how to troubleshoot this problem. Any help would be greatly appreciated, thanks!

    Read the article

  • Validation problem with a 'JotForm' template

    - by Thomas
    A client sent me a form template they had created using jotform.com to implement on their wordpress site. The form template is supposed to hide part of the form until the user clicks the 'next' button. At which point a script is supposed to validate all of the input fields the user has presumably filled out and then display the rest of the form. While I have successfully managed to get the form to display the next part of the form when the user clicks 'next', it fails to validate the input fields. Its kind of difficult to explain without a huge block of text so it is probably easier to show you: The original working template that the customer sent me: http://www.loftist.com/jotform/List_Your_Loft.html The problem child: http://www.loftist.com/?page_id=78 If you just click on one of the input fields and then click elsewhere on the page, the input fields successfully return a validation error message and prevent the user from clicking on the 'next' button. However, if you simply click on the next button than the next set of fields get displayed. Any thoughts? What am I doing wrong here? Im convinced this must be a really simple problem but Im not sure what it could be....

    Read the article

< Previous Page | 31 32 33 34 35 36 37 38 39 40 41 42  | Next Page >