Nginx configuration problem, solve!

here is my nginx configuration

server{
    listen       80;
        server_name  t1.xxx.com;
        
      location / {
            root /t001/html;
            index index.html index.htm;
      }
  
    location ^~ /c/ {
            root /t001/car/;
        }
  
      access_log  off;
}

I want to browse t1.xxx.com/c/1551059250.jpg
and return t001/car/1551059250.jpg

Why did I return 404 from the above? Ask your friends for advice! Thank you!

Jul.10,2022

in the case of using root, the file will be judged with the prefix / t001/car/c/1551059250.jpg. The actual search is / t001/car/c/1551059250.jpg , which can be changed to alias

.
location ^~ /c/ {
    alias /t001/car/;
    try_files $uri /index.html;
}
MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1cef290-39c10.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1cef290-39c10.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?