Search Results

Search found 87 results on 4 pages for 'philippe beaudoin'.

Page 3/4 | < Previous Page | 1 2 3 4  | Next Page >

  • Forbidden - 403 error Apache

    - by philippe
    I was setting my local Apache server to run Python cgi, then I came with the following error: Forbidden You don't have permission to access /hw10/main.cgi on this server. What I've changed on my http config file was: ScriptAlias /cgi-bin/ "/var/www/cgi-bin/" <Directory "/var/www/cgi-bin"> AllowOverride None Options FollowSymLinks +ExecCGI Order allow,deny Allow from all Require all granted </Directory> AddHandler cgi-script .cgi .py May someone please help me with that? I was trying to configure my Apache server to run .cgi Python scripts, and I came across that.

    Read the article

  • Sécurité informatique : Cours et exercices corrigés, critique par Vallée Nicolas et Benwit

    Bonjour La rédaction de DVP a lu pour vous l'ouvrage suivant: Sécurité informatique : Cours et exercices corrigés de Gildas Avoine, Pascal Junod, Philippe Oechslin paru aux Éditions Vuibert [IMG]http://ecx.images-amazon.com/images/I/411odAhqrbL._SS500_.jpg[/IMG] Citation: Les attaques informatiques sont aujourd'hui l'un des fléaux de notre civilisation. Chaque semaine amène son lot d'alertes concernant ...

    Read the article

  • How to display different value with ComboBoxTableCell?

    - by Philippe Jean
    I try to use ComboxBoxTableCell without success. The content of the cell display the right value for the attribute of an object. But when the combobox is displayed, all items are displayed with the toString object method and not the attribute. I tryed to override updateItem of ComboBoxTableCell or to provide a StringConverter but nothing works. Do you have some ideas to custom comboxbox list display in a table cell ? I put a short example below to see quickly the problem. Execute the app and click in the cell, you will see the combobox with toString value of the object. package javafx2; import javafx.application.Application; import javafx.beans.property.adapter.JavaBeanObjectPropertyBuilder; import javafx.beans.value.ObservableValue; import javafx.collections.FXCollections; import javafx.collections.ObservableList; import javafx.scene.Scene; import javafx.scene.control.TableCell; import javafx.scene.control.TableColumn; import javafx.scene.control.TableColumn.CellDataFeatures; import javafx.scene.control.TableView; import javafx.scene.control.cell.ComboBoxTableCell; import javafx.stage.Stage; import javafx.util.Callback; import javafx.util.StringConverter; public class ComboBoxTableCellTest extends Application { public class Product { private String name; public Product(String name) { this.name = name; } public String getName() { return name; } public void setName(String name) { this.name = name; } } public class Command { private Integer quantite; private Product product; public Command(Product product, Integer quantite) { this.product = product; this.quantite = quantite; } public Integer getQuantite() { return quantite; } public void setQuantite(Integer quantite) { this.quantite = quantite; } public Product getProduct() { return product; } public void setProduct(Product product) { this.product = product; } } public static void main(String[] args) { launch(args); } @Override public void start(Stage stage) throws Exception { Product p1 = new Product("Product 1"); Product p2 = new Product("Product 2"); final ObservableList<Product> products = FXCollections.observableArrayList(p1, p2); ObservableList<Command> commands = FXCollections.observableArrayList(new Command(p1, 20)); TableView<Command> tv = new TableView<Command>(); tv.setItems(commands); TableColumn<Command, Product> tc = new TableColumn<Command, Product>("Product"); tc.setMinWidth(140); tc.setCellValueFactory(new Callback<TableColumn.CellDataFeatures<Command,Product>, ObservableValue<Product>>() { @Override public ObservableValue<Product> call(CellDataFeatures<Command, Product> cdf) { try { JavaBeanObjectPropertyBuilder<Product> jbdpb = JavaBeanObjectPropertyBuilder.create(); jbdpb.bean(cdf.getValue()); jbdpb.name("product"); return (ObservableValue) jbdpb.build(); } catch (NoSuchMethodException e) { System.err.println(e.getMessage()); } return null; } }); final StringConverter<Product> converter = new StringConverter<ComboBoxTableCellTest.Product>() { @Override public String toString(Product p) { return p.getName(); } @Override public Product fromString(String s) { // TODO Auto-generated method stub return null; } }; tc.setCellFactory(new Callback<TableColumn<Command,Product>, TableCell<Command,Product>>() { @Override public TableCell<Command, Product> call(TableColumn<Command, Product> tc) { return new ComboBoxTableCell<Command, Product>(converter, products) { @Override public void updateItem(Product product, boolean empty) { super.updateItem(product, empty); if (product != null) { setText(product.getName()); } } }; } }); tv.getColumns().add(tc); tv.setEditable(true); Scene scene = new Scene(tv, 140, 200); stage.setScene(scene); stage.show(); } }

    Read the article

  • What is the difference between "ORA-12571: TNS packet writer failure" and "ORA-03135: connection los

    - by Philippe
    I am working in an environment where we get production issues from time to time related to Oracle connections. We use ODP.NET from ASP.NET applications, and we suspect the firewall closes connections that have been in the connection pool too long. Sometimes we get an "ORA-12571: TNS packet writer failure" error, and sometimes we get "ORA-03135: connection lost contact." I was wondering if someone has run into this and/or has an understanding of the difference between the 2 errors.

    Read the article

  • Setting encoding in Grails controller's render method

    - by Philippe
    Hello, I'm trying to build an RSS feed using Grails and Rome. In my controller's rss action, my last command is : render(text: getFeed("rss_2.0"), contentType:"application/rss+xml", encoding:"ISO-8859-1 ") However, when I navigate to my feed's URL, the header is : <?xml version="1.0" encoding="UTF-8"?> <rss xmlns:dc="http://purl.org/dc/elements/1.1/" version="2.0"> ... Does anyone have a clue about WHY the encoding is UTF-8 when I set it to ISO-8859-1 in the render method ??? Thanks for your help !

    Read the article

  • Java 1.4 singleton containing a mutable field

    - by Philippe
    Hi, I'm working on a legacy Java 1.4 project, and I have a factory that instantiates a csv file parser as a singleton. In my csv file parser, however, I have a HashSet that will store objects created from each line of my CSV file. All that will be used by a web application, and users will be uploading CSV files, possibly concurrently. Now my question is : what is the best way to prevent my list of objects to be modified by 2 users ? So far, I'm doing the following : final class MyParser { private File csvFile = null; private static Set myObjects = Collections.synchronizedSet(new HashSet); public synchronized void setFile(File file) { this.csvFile = file; } public void parse() FileReader fr = null; try { fr = new FileReader(csvFile); synchronized(myObjects) { myObjects.clear(); while(...) { // foreach line of my CSV, create a "MyObject" myObjects.add(new MyObject(...)); } } } catch (Exception e) { //... } } } Should I leave the lock only on the myObjects Set, or should I declare the whole parse() method as synchronized ? Also, how should I synchronize - both - the setting of the csvFile and the parsing ? I feel like my actual design is broken because threads could modify the csv file several times while a possibly long parse process is running. I hope I'm being clear enough, because myself am a bit confused on those multi-synchronization issues. Thanks ;-)

    Read the article

  • How to create a database and populate it during setup

    - by Philippe
    I would like to find a way to create and populate a database during asp.net setup. So, what I'm willing to do is: Create the database during the setup Populate the database with some initial data (country codes or something like that) Create the appropriate connection string in the configuration file I'm using .NET 3.5 and Visual Studio 2005, and the Database is SQL Server 2005. Thanks in advance.

    Read the article

  • How to join a table in symfony (Propel) and retrieve object from both table with one query

    - by Jean-Philippe
    Hi, I'm trying to get an easy way to fetch data from two joined Mysql table using Propel (inside Symfony) but in one query. Let's say I do this simple thing: $comment = CommentPeer::RetrieveByPk(1); print $comment->getArticle()->getTitle(); //Assuming the Article table is joined to the Comment table Symfony will call 2 queries to get that done. The first one to get the Comment row and the next one to get the Article row linked to the comment one. Now, I am trying to find a way to make all that within one query. I've tried to join them using $c = new Criteria(); $c->addJoin(CommentPeer::ARTICLE_ID, ArticlePeer::ID); $c->add(CommentPeer::ID, 1); $comment = CommentPeer::doSelectOne($c); But when I try to get the Article object using $comment->getArticle() It will still issue the query to get the Article row. I could easily clear all the selected columns and select the columns I need but that would not give me the Propel object I'd like, just an array of the query's raw result. So how can I get a populated propel object of two (or more) joined table with only one query? Thanks, JP

    Read the article

  • Generating PDF files from .NET by using standard .NET GDI printing classes

    - by Philippe Leybaert
    I'm looking for a way to generate PDF files using the standard PrintDocument and Graphics (GDI) classes in .NET. As far as I know, the only way to do that is by printing to a PDF printer. The problem is that a PDF printer driver always asks for a filename, but I need to control the filename from my code. Using a PDF library like PDFSharp or DynamicPDF is not an option, because they all provide their own API for generating PDF files. I need this for an internal application, so dependencies are not a problem. My question is simple: is there a way to control a printer driver (Adobe Acrobat, PDFCreator, ...) in such a way that a filename can be specified and the user is not prompted for anything?

    Read the article

  • MSCT Certification, Exam 70-536, your advices?

    - by Philippe
    At the beginning of the year, I was proposed by my company to take some MS certification exams. Since then, they generously paid for the Self-Paced Training Kit book. I was promised to have some time to study, but the project is running late (a habit around here). Let's face it, I'll have to study on my own time to get this certification. Anyway, my question is simple: what advices do you have in order to study effectively? I'm halfway trough the book, and I feel like I don't remember anything. Especially when the questions are so precise on classes name and parameters...

    Read the article

  • Does cout need to be terminated with a semicolon ?

    - by Philippe Harewood
    I am reading Bjarne Stroustrup's Programming : Principles and Practice Using C++ In the drill section for Chapter 2 it talks about various ways to look at typing errors when compiling the hello_world program #include "std_lib_facilities.h" int main() //C++ programs start by executing the function main { cout << "Hello, World!\n", // output "Hello, World!" keep_window_open(); // wait for a character to be entered return 0; } In particular this section asks: Think of at least five more errors you might have made typing in your program (e.g. forget keep_window_open(), leave the Caps Lock key on while typing a word, or type a comma instead of a semicolon) and try each to see what happens when you try to compile and run those versions. For the cout line, you can see that there is a comma instead of a semicolon. This compiles and runs (for me). Is it making an assumption ( like in the javascript question: Why use semicolon? ) that the statement has been terminated ? Because when I try for keep_terminal_open(); the compiler informs me of the semicolon exclusion.

    Read the article

  • WPF Binding : Object in a object

    - by Philippe
    I have a form in WPF with 2 textbox : <TextBox Name="txtName" Text="{Binding Contact.Name}"/> <TextBox Name="txtAddressNumber" Text="{Binding Contact.Address.Number}"/> and I have 2 class : public class ContactEntity { public string Name {get;set;} public AddressEntity Address {get;set;} } public class AddressEntity { public int Number {get;set} } The Name property binds fine. But the Number property of the Address object inside the Contact object does not binds. What I'm doing wrong ?

    Read the article

  • How to add condition on multiple-join table

    - by Jean-Philippe
    Hi, I have those two tables: client: id (int) #PK name (varchar) client_category: id (int) #PK client_id (int) category (int) Let's say I have those datas: client: {(1, "JP"), (2, "Simon")} client_category: {(1, 1, 1), (2, 1, 2), (3, 1, 3), (4,2,2)} tl;dr client #1 has category 1, 2, 3 and client #2 has only category 2 I am trying to build a query that would allow me to search multiple categories. For example, I would like to search every clients that has at least category 1 and 2 (would return client #1). How can I achieve that? Thanks!

    Read the article

  • SQL Server many-to-many design recommendation

    - by Jean-Philippe Brabant
    I have a SQL Server database with two table : Users and Achievements. My users can have multiple achievements so it a many-to-many relation. At school we learned to create an associative table for that sort of relation. That mean creating a table with a UserID and an AchivementID. But if I have 500 users and 50 achievements that could lead to 25 000 row. As an alternative, I could add a binary field to my Users table. For example, if that field contained 10010 that would mean that this user unlocked the first and the fourth achievements. Is their other way ? And which one should I use.

    Read the article

  • get_post_meta return empty string

    - by Jean-philippe Emond
    I guest it is a little issues but I running a SQL to get some post id. $result = $wpdb->get_results("SELECT wppm.post_id FROM wp_postmeta wppm INNER JOIN wp_posts wpp ON wppm.post_id=wpp.ID WHERE wppm.meta_key LIKE 'activity'"); (count: 302) After that, I get all id and I run get_post_meta like that: foreach($result as $id){ $activity = get_post_meta($id); var_dump($activity); foreach($activity as $key=>$value){ if(is_array($value) && $key=="age"){ var_dump($value); } } } (var_dump result: string "") samething if I run with: $activity = get_post_meta($id,'activity',true); Where we need to get a result. What is wrong? Thank you for your help!!! [Bonus Question] If the "activity" meta_key as an array Value. and I get directly like: $result = $wpdb->get_results("SELECT wppm.meta_value FROM wp_postmeta wppm INNER JOIN wp_posts wpp ON wppm.post_id=wpp.ID WHERE wppm.meta_key LIKE 'activity'"); How I parse it? Thanks again!

    Read the article

  • ADO.NET connection string and password with "=" in it

    - by Philippe Leybaert
    How do I build a connection string which includes a passsword having a "=" in it? (I'm connecting to MySql 5.1) For example, let's say the password is "Ge5f8z=6", what would the connection string look like? I tried: Server=DBSERV;Database=mydb;UID=myuser;PWD="Ge5f8z=6"; and Server=DBSERV;Database=mydb;UID=myuser;PWD=Ge5f8z=6;" Both don't work.

    Read the article

  • Xcode Code Sense horribly broken?

    - by Philippe Leybaert
    Ever since I started using Xcode, I've experienced extremely annoying problems using Xcode and Code Sense. The problem is that when Code Sense kicks in for code completion, sometimes the source code text below the line I'm working on goes "crazy". If I continue typing, the problem gets worse, and after a while the source code is completely screwed up (funny colors, missing lines and characters, ...). Strange enough, the source code itself is unaffected, because when I select another source file and then go back to the one I was working on, everything looks fine again. The problem can be seen in this screencast: http://www.screencast.com/t/OGY3NWE5 Interesting facts: This problem has occurred on 3 different machines, so it's not related to a corrupt installation. Sometimes it's fine for a while (up to one hour) after launching Xcode, but once it starts happening, it's getting worse and worse, until Xcode is restarted. Then it's fine again (for a while) I've searched the web for similar experiences, and I can't find anything. I would think that it is a known problem, since it occurs on 3 different Macs here (both running 10.5 and 10.6). Anyone having the same problems? Or a suggestion for fixing this?

    Read the article

  • Why junit ComparisonFailure is not used by assertEquals(Object, Object) ?

    - by Philippe Blayo
    In Junit 4, do you see any drawback to throw a ComparisonFailure instead of an AssertionError when assertEquals(Object, Object) fails ? assertEquals(Object, Object) throws a ComparisonFailure if both expected and actual are String an AssertionError if either is not a String @Test(expected=ComparisonFailure.class ) public void twoString() { assertEquals("a String", "another String"); } @Test(expected=AssertionError.class ) public void oneString() { assertEquals("a String", new Object()); } The two reasons why I ask the question: ComparisonFailure provide far more readable way to spot the differences in dialog box of eclipse or Intellij IDEA (FEST-Assert throws this exception) Junit 4 already use String.valueOf(Object) to build message "expected ... but was ..." (format method invoqued by Assert.assertEquals(message, Object, Object) in junit-4.8.2): static String format(String message, Object expected, Object actual) { ... String expectedString= String.valueOf(expected); String actualString= String.valueOf(actual); if (expectedString.equals(actualString)) return formatted + "expected: " + formatClassAndValue(expected, expectedString) +" but was: " + formatClassAndValue(actual, actualString); else return formatted +"expected:<"+ expectedString +"> but was:<"+ actualString +">"; Isn't it possible in assertEquals(message, Object, Object) to replace fail(format(message, expected, actual)); by throw new ComparisonFailure(message, formatClassAndValue(expectedObject, expectedString), formatClassAndValue(actualObject, actualString)); Do you see any compatibility issue with other tool, any algorithmic problem with that... ?

    Read the article

  • video player for HTML 5 page not loading

    - by philippe
    I'm using VideoJS to as my video player for a project I've been working on. Basically I have a div, and I wanted to have the video player within that div, however when I load the page nothing happens, and the video is never played. In fact, the video is never loaded nor shown in the page. I basically copied the example from VideoJS' page. Any thoughts? <div class="video-js-box"> <!-- Using the Video for Everybody Embed Code http://camendesign.com/code/video_for_everybody --> <div style="position: absolute; top: 50px; left: 600px; display:none"> <video id="example_video_1" class="video-js vjs-default-skin" controls preload="auto" width="640" height="264" poster="http://video-js.zencoder.com/oceans-clip.png" data-setup='{"example_option":true}'> <source src="http://video-js.zencoder.com/oceans-clip.mp4" type='video/mp4'></source> <source src="http://video-js.zencoder.com/oceans-clip.webm" type='video/webm'>></source> <source src="http://video-js.zencoder.com/oceans-clip.ogv" type='video/ogg'></source> </video> <!-- Download links provided for devices that can't play video in the browser. --> <p class="vjs-no-video"><strong>Download Video:</strong> <a href="http://video-js.zencoder.com/oceans-clip.mp4">MP4</a>, <a href="http://video-js.zencoder.com/oceans-clip.webm">WebM</a>, <a href="http://video-js.zencoder.com/oceans-clip.ogv">Ogg</a><br> <!-- Support VideoJS by keeping this link. --> <a href="http://videojs.com">HTML5 Video Player</a> by VideoJS </p> </div> <div style="clear:both;"></div> </div><!--main-->

    Read the article

  • regular expression not behaving as expected - Python

    - by philippe
    I have the following function which is supposed to read a .html file and search for <input> tags, and inject a <input type='hidden' > tag into the string to be shown into the page. However, that condition is never met:( e.g the if statement is never executed. ) What's wrong with my regex? def print_choose( params, name ): filename = path + name f = open( filename, 'r' ) records = f.readlines() print "Content-Type: text/html" print page = "" flag = True for record in records: if re.match( '<input*', str(record) ) != None: print record page += record page += "<input type='hidden' name='pagename' value='psychology' />" else: page += record print page Thank you

    Read the article

< Previous Page | 1 2 3 4  | Next Page >