Posts

replace - How to use the new image replacement technique by Scott Kellum -

i practicing using various image replacement methods , came across couple articles discussing new, supposedly more efficient method scott kellum. original website article regarding new method it seems , practice using it, not sure html , css should be. in example below, have h1, example logo text inside. added class of .hide-text h1 , styled css. used photoshop logo image made , set background image....the image has width of 203px , height of 57px. question 1: when tested code in browser, seems working fine, usage of mr.kellum's image replacement technique correct? question 2: should target h1 in css , declare width , height or okay include width , height directly in hide-text class in example below? <style> .hide-text { background: url(images/mylogo.jpg) 0 0 no-repeat; text-indent: 100%; white-space: nowrap; overflow: hidden; width: 203; height: 57px; } <body> <h1 class="hide-text">mylogo text</h1> ...

java - Axis - Response class extends AxisFault and is thrown instead of returned? -

i have generated java class files using axis1 (axis-1.4.jar). have ws method call (i can see generated java code too). say method call accepts requesta parameter , returns object of type responsea. problem have responsea extends axisfault (i can see in generated java source file responsea). axisfault on own turn extends remoteexception. as result of this, responsea object returned not returned me thrown to/at me remoteexception. so when this try { responsea x = call(y); // y requesta } catch (exception ex) { ex.printstacktrace(); } in client code, flow of control goes catch block , catching should getting in x variable (i.e. ex x be). any idea makes axis generate responsea class subclass of axisfault? also, in general, when class generated axis, generated subclass of axisfault? i think current problem. think in weird situation response succesful ws method call not returned me instead thrown to/at me. many in advance. package com.test.fulfillme...

sql server - "Unable to load the specified metadata resource" ASP.NET -

i getting error " unable load specified metadata resource ". new asp.net , following tutorial: http://www.asp.net/web-forms/tutorials/tailspin-spyworks/tailspin-spyworks-part-2 i using visual studio 2012 , ms server 2012 unlike tutorial , chose new website not web app when starting site. i created entity data source control , created ado.net entity data entry database provided. when try use control error. i read connection string here mine. have spent hours trying fix it, can help? here connection string: <add name="entities" connectionstring=" metadata=res://*/data_access.edm_commerce.csdl| res://*/data_access.edm_commerce.ssdl| res://*/data_access.edm_commerce.msl; provider=system.data.sqlclient;provider connection string='data source=owen;initial catalog=commerce.mdf;integrated security=true;multipleactiveresultsets=true;app=entityframework';" providername="system.data.entityclient" /> i have tried changing conne...

How do I tell a C program to create n arrays, reading n by scanf? -

i'd create small program adds, subtracts, multiplies , cross product vectors. therefore i'd have user enter - amount of vectors - dimension of said vectors - wants vectors (one of above mentioned functions) since quite new programming maybe haven't found correct source yet, in case grateful hint in right direction (especially search exactly, since not native speaker) my problem: i don't know how program sum function sums n vectors (n being amount of vectors user entered) i have rough idea rest of functions maybe won't bother program again sum-problem problem me. i'm sure answer somewhere near don't seem able find it. so many in advance :) simple vector #include <stdio.h> #include <stdlib.h> #include <string.h> typedef int type; typedef struct vector { size_t size; size_t capacity; type *array; } vector; vector *vec_make(){ vector *v; v = (vector*)malloc(sizeof(vector)); v->size = 0...

schema - How to update a table based on an update from another table in oracle? -

i have table t1 present in schema s1. table t2 schema s2. both t1 , t2 have primary keys p1 , q1. i want update t1 updated q1 t2 p1. tried writing trigger doesnot helped me there no privileges because s1 application schema , s2 product schema. please let me know best solution implement same. in advance. i'm not oracle's expert think sql server have same sintax: update s1..t1 set field = tab2.field s1..t1 tab1 inner join s2..t2 tab2 on tab1.p1 = tab2.q1

Serving protected files with Django and Nginx X-accel-redirect -

i'm trying nginx , django play serve downloadable protected files. cannot work. here's nginx config: location ~ ^.*/protected-test/ { alias /<path-to-my-protected-files-on-server>/; internal; } the relevant urls.py viewing file(s): url(r'^static_files/downloads/protected-test/(?p<filename>.+)$', 'download_or_view', {'download_dir': '%s%s' % (settings.media_root, 'downloads/protected-test/'), 'content_disposition_type': 'inline', 'protected': 'true'}, name='protected_files') my view: def download_or_view(request, content_disposition_type, download_dir, filename=none, protected=false): '''allow file downloaded or viewed,based on request type , content disposition value.''' if request.method == 'post': full_path = '%s%s' % (download_dir, request.post['filename']) short_filename = str(request.post['filename'...

javascript - drag and drop not working, dont allow drop on a div -

im trying create aplication using drag , drop. when im trying drop element on div called 'serviciosarealizar', doesnt allow. please html <div id='aceite' draggable="true" ondragstart="arrastrar(event)"><img src='img/aceite.jpg' /></div> <div id='luces' draggable="true" ondragstart="arrastrar(event)"><img src='img/lamp.png' /></div> <div id='serviciosarealizar' ondrop='soltar(event)' ondragover='permitesoltar(event)'></div> javascript <script> function permitesoltar(ev){ ev.preventdefault(); } function soltar(ev){ ev.preventdefault(); var data=ev.datatransfer.getdata("text"); ev.target.appendchild(document.getelementbyid(data)); } function arrastrar(ev){ ev.datatransfer.setdata("text",ev.target.id); } </scrip...