How to allow Access-Control-Allow-Origin in PHP?


#1

I need to load font on the server side

index.html
sfont.otf

@font-face {
font-family: Avenir;
src: url('avenir-lt-std-roman.otf');}

#2

Could you open a support ticket regarding this. We will need more information as you say you are trying to do this via PHP but are using html files.


#3

@RobertG sorry i mean apache server

i try to access hta access file

so i can configure it

thank

i read on QA site

that i have to write Access-Control-Allow-Origin in hta access file

so how to do this if gearhost doesn supports the hta access file


#4

Hello

.htaccess is used for apache web servers. Our servers use IIS, the web.config is similar to .htaccess but the code will be different. You can use a converter like

Keep in mind these converters are not always accurate. http://cbsa.com.br/tools/online-convert-htaccess-to-web-config.aspx